Hi there,

I am working on the Foundation libraries of open source Swift. The
implementation of URLSession there, uses libcurl underneath.

There's an issue where we make ~180 GET calls to the *same endpoint* (the
GitHub API). Internally, for each GET call we seem to be configuring an
easy handle and then registering it with a multi handle. In one of these
iterations (randomly), I see libcurl returning CURLE_CANNOT_CONNECT.

So, I turned on the verbose mode and before each transfer I could see this:
[1]                   Connection #0 to host api.github.com left intact

Only, before the failing connection, I see:
[1]                   Connection #0 to host api.github.com left intact
[1]                   Closing connection 0`

Nothing else is logged on failure. When I try to use strace, to find the
failing system call, the failure gets masked.

I am not sure how to proceed with the analysis. Can someone please help me
take this further, please?
-------------------------------------------------------------------
List admin: https://cool.haxx.se/list/listinfo/curl-library
Etiquette:  https://curl.haxx.se/mail/etiquette.html

Reply via email to