Memcache connection errors
timeless
time at digg.com
Wed May 24 23:53:30 UTC 2006
Reinis Rozitis wrote:
> $mc = new Memcache;
> if (!$mc->connect('127.0.0.1',11212)) {
> $mc->connect('127.0.0.1',11212); }
In this case, if the memcached on 127.0.0.1 never answers, you'll wait 2
seconds before failing to get the connection?
To the list, is there a way to get sub-second connection timeouts?
I'd kind of like to implement exactly this, but our memcached cluster is
about 9 hosts, and if any one is down, it would cause executive-level
despondancy if the site went from 0.5-second page render times to
2.5-second page render times until we pulled the errant memcached
instance out of the pool.
(Or does the timeout only apply if something answers on 11211, but never
gives back proper protocol responses?)
--
timeless
More information about the memcached
mailing list