Hey all,
I've got a pull request at https://github.com/php/php-src/pull/15603
that I wanted to bring to your attention. We're interested in being
able to reuse curl share handles across requests in mod_php, since
we'd expect a performance benefit from not having to redo DNS lookups
(in the case of CURL_LOCK_DATA_DNS) or having to re-establish
connections (in the case of CURL_LOCK_DATA_CONNECT).
I'm not tied to the specific implementation in my PR, though I'll note
that I ran into an issue with calling curl_share_setopt with
CURL_LOCK_DATA_CONNECT
that makes it preferable to be able to
initialize the curl share handle once with the share options. I've
fixed that issue in https://github.com/curl/curl/pull/14696, but of
course that won't be available for most people for quite some time.
Thanks!
Eric Norris
Apologies for any noise, but I'd like to bump this thread to poll for
input on whether people feel this pull request requires an RFC, and if
so, request RFC karma so that I may submit an RFC. I've already got
one vote from @SakiTakamachi for requiring an RFC.
I had an interesting discussion with @cmb69 and @kocsismate about
internal persistent resources, and the updated version of the PR
relies on PHP_MODULE_GLOBALS instead. I think there are some open
questions going forward around how to deal with existing internal
persistent resources, so I'm curious to know how php-internals
addresses them in the future, but will leave that aside for now.