On Mon, 15 Jan 2018, Michael Kilburn wrote:

It doesn't seem to work for me -- I've crated a shared cache of easy handles, after thread is done sending data, it returns handle (CURL*) into cache (actually, stack). But on server side accept queue size is always 20-30 while client is sending data (and performance has barely changed).

I'm sorry but I don't understand what you're trying to achieve nor how you do it.

curl_easy_setopt(CURLOPT_WRITEFUNCTION, ...)      // func discards incoming
data

I trust this callback return the correct value still? Otherwise it'll probably cause the connection to get closed.

curl_easy_perform()

In the easy interface (that you are using when _easy_perform is called), the connection cache is held in the easy handle so unless you share the connection cache between handles you must make sure to re-use a handle that was previously used to communicate with the same host as otherwise it won't have the previous connection in its cache...

Maybe one of these options prevent tcp connection (and related TLS session key) from being reused?

Connections can also get closed by the server's decisions.

--

 / daniel.haxx.se
-------------------------------------------------------------------
Unsubscribe: https://cool.haxx.se/list/listinfo/curl-library
Etiquette:   https://curl.haxx.se/mail/etiquette.html

Reply via email to