-
Notifications
You must be signed in to change notification settings - Fork 29
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
dns lookup is not cached the way I understand #67
Comments
Can you confirm if manually using https://nodejs.org/api/dns.html#dnsresolve4hostname-options-callback returns data? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hello there,
I could be missing something here.
I am trying to reduce the calls that go to
dns.lookup
in order to reduce the C++ libuv threads allocation so I am using this library.How I am testing that, by running this code:
so, without installing this library I can see a lot of dns lookups.
Now after I installed this library with its global http(s) agent as follows:
I was expecting the number of dns lookups would go down and cache hits to happen, but it did not!
I see from the logs that the same hostname with the same family are still calling the native dns.lookup and not served from a cache.
The text was updated successfully, but these errors were encountered: