node.js http.request and ipv6 vs ipv4
问题 In node.js 4.x for the function http.request the docs say Options family: IP address family to use when resolving host and hostname. Valid values are 4 or 6. When unspecified, both IP v4 and v6 will be used. What is the logic behind when node.js will choose ipv6 or ipv4 when family is not specified? As far as I can tell when I don't specify it it defaults to or prefers ipv4 whereas browsers, at least, chrome, prefers ipv6 Is there a way to get node.js to choose ipv6 when available or do I