memcache

Permalink
Anyone know how to configure C5 to use memcache as the default? Assuming memcache servers are NOT running on the same box (so, connect to a pool of memcache servers)?

Thanks in advance.

Jon

focus43
 
Remo replied on at Permalink Reply
Remo
It's not something I'm using, but try something like this:

define('CACHE_LIBRARY', 'memcached');
define('CACHE_BACKEND_OPTIONS', serialize(array(array('host' => 'localhost', 'port' => 11211, 'persistent' => true, 'weight' => 1, 'timeout' => 5, 'retry_interval' => 15, 'status' => true, 'failure_callback' => '' ))));


put these lines in config/site.php and concrete5 should be looking for a memcached server on localhost.

there are two constants CACHE_BACKEND_OPTIONS and CACHE_FRONTEND_OPTIONS which you can use to serialize Zend Cache settings. Check this page if you need for information about the options you can specify:http://framework.zend.com/manual/1.12/en/zend.cache.backends.html...

But keep in mind that Zend Cache has less use in 5.6.1 (the upcoming release of concrete5). It might be a waste of time to look into memcached as some of my testsites run a lot better with 5.6.1.

This website stores cookies on your computer. These cookies are used to improve your website experience and provide more personalized services to you, both on this website and through other media. To find out more about the cookies we use, see our Privacy Policy.