- Issue created by @o'briat
The PECL memcached extension allows the automatic removal of dead servers. This feature could allows this module to use the remaining cache server. At the moment, a missing server equals no cache at all (but no White Screen Of Death as with Redis).
With this feature, this module will be way more resilient.
See: https://holmeshe.me/understanding-memcached-source-code-X-consistent-has... & https://www.php.net/manual/en/memcached.addservers.php
$settings['memcache']['servers'] = ["memcached:11211" => "default", "memcached2:11211" => "default"];
$settings['memcache']['options'][Memcached::OPT_SERVER_FAILURE_LIMIT] = 2;
$settings['memcache']['options'][Memcached::OPT_REMOVE_FAILED_SERVERS] = true;
$settings['memcache']['options'][Memcached::OPT_CONNECT_TIMEOUT] = 10;
The performance are terrible and the stats page display an error.
Have a main maintainer confirm my diagnostic and determine if a fix could be made without rewriting the whole module or losing the memcache PECL compatibilty.
So far, my first approach was to "xdebug it" and catch each errors related to missing server.
Here's my first thoughts:
$settings['memcache']['servers']
, get the servers list from Memcached::getServerList
Some new methods should be created.
Active
2.0
Code