curl / Mailing Lists / curl-library / Single Mail
Buy commercial curl support from WolfSSL. We help you work out your issues, debug your libcurl applications, use the API, port to new platforms, add new features and more. With a team lead by the curl founder himself.

Re: Couldn't connect to host (err: 7)

From: Hadi Rezaee via curl-library <curl-library_at_cool.haxx.se>
Date: Mon, 21 Sep 2020 14:08:02 +0330

Sorry, maybe I explained bad.
My point is that curl handlers are already reusing connections. (with the
same setup that I explained earlier)

For example in a happy-scenario (no failures - err no 7) and when I reduce
the REST calls per second to 50 from the client side. I only see 6~8
established connections (netstat -an | grep 8880)
Which is fine.

When I increase REST call per second to higher values (300, 400, ..), more
persistent connections are getting used (which I think it is expected
right?)

On Mon, Sep 21, 2020 at 12:50 PM Daniel Stenberg <daniel_at_haxx.se> wrote:

> On Mon, 21 Sep 2020, Hadi Rezaee wrote:
>
> > Then threads will look into the list to find a curl-handler that its
> mutex
> > is not locked, and then use the free curl-handler to submit the request
> > (perform()) And finally when we're done with a handler, we'd "call
> > curl_easy_reset".
>
> That doesn't quite explain why they don't reuse connections to a higher
> degree
> though... I would recommend you look into that. You should also get a
> significant performance increase if you fix that.
>
> --
>
> / daniel.haxx.se | Commercial curl support up to 24x7 is available!
> | Private help, bug fixes, support, ports, new features
> | https://www.wolfssl.com/contact/
>

-------------------------------------------------------------------
Unsubscribe: https://cool.haxx.se/list/listinfo/curl-library
Etiquette: https://curl.haxx.se/mail/etiquette.html
Received on 2020-09-21