-
-
Notifications
You must be signed in to change notification settings - Fork 7.1k
Description
Similar to #2975.
I did this
Two or three dozen transfers in a multi to the same host concurrently. When the threaded resolver is used (maybe c-ares as well?) this causes the same amount of concurrent resolves. Occasionally one of the resolves will not receive a reply or it is delayed by 5-10 seconds. (It is a network issue and I haven't investigated it yet, possibly has to do with so many being sent at once.) However the other resolves will succeed and since libcurl is opportunistic with the DNS cache all the transfers will succeed. The problem is when the transfer that has the pending resolve is transfer done but not resolve done it hangs waiting for that resolve thread to end which holds up any other transfer that hasn't completed.
I expected the following
As discussed in #2975 if the thread can clean up its own resources I don't think libcurl should hang waiting for it. Also is it intentional that multiple resolves for the same host are sent out when pipewait is not used?
I wrote a small program to test out the different methods, I only occasionally get somewhat arbitrary results when testing multi without pipewait.
curl/libcurl version
libcurl/7.69.0-DEV OpenSSL/1.0.2t nghttp2/1.40.0
Asynchronous DNS (threaded)
operating system
Windows 7 Enterprise