diff options
author | Vsevolod Strukchinsky <floatdrop@yandex-team.ru> | 2013-08-20 18:31:40 +0600 |
---|---|---|
committer | Fedor Indutny <fedor.indutny@gmail.com> | 2013-08-20 21:03:52 +0400 |
commit | edd2fcccf022c7014b374674012283422faa1bed (patch) | |
tree | 745a9da1c962dfeac5c7aacd3fb7794f96fdcfbc /doc/api | |
parent | 85d6b783432e1c58084c3bdebf15cf45384f6572 (diff) | |
download | node-new-edd2fcccf022c7014b374674012283422faa1bed.tar.gz |
net: family option in net.connect
`dns.lookup` defaults to selecting IPv4 record even if IPv6 is available
for the desired zone. Generally, this approach works, but if IPv4
address is unavailable - there'll be no other way to opt-out and connect using
IPv6 address than calling `dns.lookup` and passing it to `.connect()`
directly.
This commit adds `family` option to `net.connect` method to figure out
this issue.
Diffstat (limited to 'doc/api')
-rw-r--r-- | doc/api/net.markdown | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/doc/api/net.markdown b/doc/api/net.markdown index 34de227478..1d7b6d2dda 100644 --- a/doc/api/net.markdown +++ b/doc/api/net.markdown @@ -64,6 +64,8 @@ For TCP sockets, `options` argument should be an object which specifies: - `localAddress`: Local interface to bind to for network connections. + - `family` : Version of IP stack. Defaults to `4`. + For UNIX domain sockets, `options` argument should be an object which specifies: - `path`: Path the client should connect to (Required). |