In my project I do a big amount of request to the same url using the 'request' module. For some reason a lot of the request go to the dns server in order to resolve the url address instead of having some sort of caching for this. Is there some kind of built-in mechanism in the 'request' module to resolve this? Or any other solution?
Thanks!
This question is a little old so you may have already found an answer, but I just had this problem and used the dnscache module to handle it. We had a high amount of IO (Node reading /etc/resolv.conf
), and this module seemed to handle the problem. I couldn't find anything in Request's or Node's source to handle that problem, but did find this related issue.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With