You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Easy handles are meant and designed to be reused. When you have done a single transfer with the easy handle, you can immediately use it again for your next transfer.
After the transfer has been made, you can set new options and make another transfer, or if you are done, cleanup the session by calling curl_easy_cleanup. If you want persistent connections, you do not cleanup immediately, but instead run ahead and perform other transfers using the same easy handle.
Actually I don't think this is so necessary after all, since we are using the multi API. The multi-handle will maintain the connection pool
When you are using the multi API, the connection pool is instead kept associated with the multi handle. This allows you to cleanup and re-create easy handles freely without risking losing the connection pool, and it allows the connection used by one easy handle to get reused by a separate one in a later transfer. Just reuse the multi handle!
Activity
armanbilge commentedon Aug 25, 2022
Keypool is not published for Native yet, but I can bootleg it real quick if someone wants to work on this. Just ping me :)
armanbilge commentedon Aug 30, 2022
Actually I don't think this is so necessary after all, since we are using the multi API. The multi-handle will maintain the connection pool
https://everything.curl.dev/libcurl/connectionreuse
Using a pool to reuse easy-handles may still be useful from a memory allocation perspective? But a pool adds overhead too.
[-]Use keypool for caching easy handles[/-][+]Pool easy handles?[/+]