php-memcache, delete, expiration questions, ideas

Antony Dovgal antony at zend.com
Mon Dec 5 09:27:13 UTC 2005


On 05.12.2005 12:18, Veres Lajos wrote:
> We are using the php pecl api with a small wrapper for able to connect 
> more servers at the same time, and with some function for 
> store/delete/fetch data from/to all servers.

Please test CVS version, it supports multiple servers using this syntax:

$memcache->addServer($host2, $port2);

bool memcache_add_server( resource connection, string host [, int port [ bool persistent [, unsigned int weight [, int timeout [, int retry_interval ] ] ] ] ])
bool Memcache::addServer( string host [, int port [ bool persistent [, unsigned int weight [, int timeout [, int retry_interval ] ] ] ] ])


> As I seen in the mailing lists, the php-pecl APIs only disadvantage it 
> cant store "server-down" information with a "correct" way.

"server-down" information?

> And a last question:
> This php pecl API allows any character in cache keys?
> As I seen the protocoll doesnt allow spaces, but in the php.net 
> documentation doesnt say anything about keyname constraints.

Characters like \t, \r, \n and ' ' are being replaced with '_' automatically.
I should probably add that to the docs.

-- 
Wbr, 
Antony Dovgal


More information about the memcached mailing list