ddth-cache-adapter-core/src/main/java/com/github/ddth/cacheadapter/cacheimpl/memcached/XMemcachedCacheFactory.java
public static MemcachedClient newMemcachedClient(String hostsAndPorts, long connTimeoutMs,
            int connPoolSize) throws IOException {
        hostsAndPorts = StringUtils.join(hostsAndPorts.split("[\\s,;]+"), ' ');
        MemcachedClientBuilder builder = new XMemcachedClientBuilder(
                AddrUtil.getAddresses(hostsAndPorts));
        builder.setConnectTimeout(connTimeoutMs);
        builder.setConnectionPoolSize(connPoolSize);
        return builder.build();
    }
public static MemcachedClient newMemcachedClient(String hostsAndPorts, long connTimeoutMs,
            int connPoolSize) throws IOException {
        hostsAndPorts = StringUtils.join(hostsAndPorts.split("[\\s,;]+"), ' ');
        MemcachedClientBuilder builder = new XMemcachedClientBuilder(
                AddrUtil.getAddresses(hostsAndPorts));
        builder.setConnectTimeout(connTimeoutMs);
        builder.setConnectionPoolSize(connPoolSize);
        return builder.build();
    }
Creates a new {@link MemcachedClient}, with specified connection timeout
and connection pool size.

@param hostsAndPorts
Memcached' hosts and ports scheme (format
{@code host1:port1,host2:port2}).
@param connTimeoutMs
@param connPoolSize
@return
@throws IOException