#include <memcache_manager.hpp>
|
| memcache_manager () |
|
virtual | ~memcache_manager () |
|
| connect_manager (void) |
|
virtual | ~connect_manager (void) |
|
void | bind_thread (bool yes) |
|
void | init (const char *default_addr, const char *addr_list, size_t count, int conn_timeout=30, int rw_timeout=30) |
|
void | set (const char *addr, size_t count, int conn_timeout=30, int rw_timeout=30) |
|
const conn_config * | get_config (const char *addr, bool use_first=false) |
|
void | set_retry_inter (int n) |
|
void | set_idle_ttl (time_t ttl) |
|
void | set_check_inter (int n) |
|
void | remove (const char *addr) |
|
connect_pool * | get (const char *addr, bool exclusive=true, bool restore=false) |
|
virtual connect_pool * | peek (void) |
|
virtual connect_pool * | peek (const char *key, bool exclusive=true) |
|
void | lock (void) |
|
void | unlock (void) |
|
std::vector< connect_pool * > & | get_pools (void) |
|
size_t | check_idle (size_t step, size_t *left=NULL) |
|
size_t | size (void) const |
|
connect_pool * | get_default_pool (void) |
|
void | statistics (void) |
|
bool | start_monitor (connect_monitor *monitor) |
|
connect_monitor * | stop_monitor (bool graceful=true) |
|
void | set_pools_status (const char *addr, bool alive) |
|
|
connect_pool * | create_pool (const char *addr, size_t count, size_t idx) |
|
void | set_service_list (const char *addr_list, int count, int conn_timeout, int rw_timeout) |
|
conns_pools & | get_pools_by_id (unsigned long id) |
|
connect_pool * | create_pool (const conn_config &cf, size_t idx) |
|
void | create_pools_for (pools_t &pools) |
|
void | remove (pools_t &pools, const char *addr) |
|
void | set_status (pools_t &pools, const char *addr, bool alive) |
|
unsigned long | get_id (void) const |
|
void | get_key (const char *addr, string &key) |
|
void | get_addr (const char *key, string &addr) |
|
connect_pool * | add_pool (const char *addr) |
|
| noncopyable () |
|
| ~noncopyable () |
|
memcache 客户端请求连接池管理类
在文件 memcache_manager.hpp 第 13 行定义.
◆ memcache_manager()
acl::memcache_manager::memcache_manager |
( |
| ) |
|
◆ ~memcache_manager()
virtual acl::memcache_manager::~memcache_manager |
( |
| ) |
|
|
virtual |
◆ create_pool()
connect_pool* acl::memcache_manager::create_pool |
( |
const char * |
addr, |
|
|
size_t |
count, |
|
|
size_t |
idx |
|
) |
| |
|
protectedvirtual |
基类纯虚函数,用来创建连接池对象
- 参数
-
addr | {const char*} 服务器监听地址,格式:ip:port |
count | {size_t} 连接池的大小限制,该值为 0 时没有限制 |
idx | {size_t} 该连接池对象在集合中的下标位置(从 0 开始) |
实现了 acl::connect_manager.
该类的文档由以下文件生成: