In our current use of memcached, we are running into problems in a high volume server because so much time is used setting up and tearing down connections to our memcache server. Would using persistent connections to memcached help alleviate this problem?
Also, what is the preferred way to connect and use persistent memcahced connections? I was thinking of setting a "pool_size" variable then randomly choosing from 1-$POOL_SIZE
and using that connection
$mem = new Memcached(rand(1, $pool_size));
Either I am looking in the wrong place or there is not a lot of information on this out there.
Both pecl/memcache and pecl/memcached support persistent connections per process. However, the bug does exist in pecl/memcached at this time.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With