update : 2015.11.03
php.shukuma.com검색:
|
Memcache::addServer(PECL memcache >= 2.0.0) Memcache::addServer — Add a memcached server to connection pool 설명
bool Memcache::addServer
( string
$host
[, int $port = 11211
[, bool $persistent
[, int $weight
[, int $timeout
[, int $retry_interval
[, bool $status
[, callable $failure_callback
[, int $timeoutms
]]]]]]]] )Memcache::addServer() adds a server to the connection pool. You can also use the memcache_add_server() function. When using this method (as opposed to Memcache::connect() and Memcache::pconnect()) the network connection is not established until actually needed. Thus there is no overhead in adding a large number of servers to the pool, even though they might not all be used. Failover may occur at any stage in any of the methods, as long as other servers are available the request the user won't notice. Any kind of socket or Memcached server level errors (except out-of-memory) may trigger the failover. Normal client errors such as adding an existing key will not trigger a failover.
인수
주의Warning
When the 반환값
성공 시 예제
Example #1 Memcache::addServer() example
<?php 참고
|