[][src]Function memcached::connect_withconnect_with

pub fn connect_withconnect_with(
    urls: Vec<String>,
    pool_size: u64,
    hash_function: fn(_: &str) -> u64
) -> Result<Client>

Create a client, you can specify multiple url, connection pool size, key hash connection pool function.

Example

let client = memcached::Client::connect_with(vec!["memcache://127.0.0.1:12345".to_owned()], 2, |s|1).unwrap();