Situation: We have several threads each with their own multi handles working with libevent. Recently we thought it'd be nice to start reusing easy handles, as the cost of creating a new one is expensive compared to curl_easy_reset. However something interesting happened, our connection reuse plummeted.
After curl_multi_socket_action is called we check if any requests are complete. All easy handles paired with CURLMSG_DONE are returned to a pool of easies to be reused. Upon being returned to the pool, if the pool is full we do curl_easy_cleanup, otherwise curl_easy_reset. Any handle that is reset can be used by any multi handle. Question: After curl_multi_info_read says a request is complete, does the easy handle still hold the connection? Then using the easy in a different multi would cause the connection to be closed? Setup: We are running libcurl 7.67 w/ c-ares 1.15.0 on Debian 9. As always thanks for the awesome tool and taking the time to answer these questions. Damon
------------------------------------------------------------------- Unsubscribe: https://cool.haxx.se/list/listinfo/curl-library Etiquette: https://curl.haxx.se/mail/etiquette.html