Re: Couldn't connect to host (err: 7)
Date: Mon, 21 Sep 2020 18:11:12 +0200 (CEST)
On Mon, 21 Sep 2020, Hadi Rezaee wrote:
> 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.
If each request takes 100ms you should be able to do 50 requests per second
using 5 connections, so with a little rounding errors 6-8 seems within the
margins.
Surely then each connection uses a single easy handle and basically just
reuses the same connection all the time?
> 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?)
I would imagine each thread would use its own connection and reuse that, yes.
With 10 request/second per thread, you need 70 threads (and connections) for
700 requests/second.
From your description it sounds like it doesn't work quite like 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.htmlReceived on 2020-09-21