public static function getMemcachedInstance(\Memcached $memcached, $maxFailures = 20, $retryTimeout = 30) {
        $storage = new ArrayDecorator(new MemcachedAdapter($memcached));
        return new CircuitBreaker($storage, $maxFailures, $retryTimeout);
    }
public static function getMemcachedInstance(\Memcached $memcached, $maxFailures = 20, $retryTimeout = 30) {
        $storage = new ArrayDecorator(new MemcachedAdapter($memcached));
        return new CircuitBreaker($storage, $maxFailures, $retryTimeout);
    }
public static function getMemcachedInstance ( \ Memcached $ memcached , $ maxFailures = 20 , $ retryTimeout = 30 ) { $ storage = new ArrayDecorator ( new MemcachedAdapter ( $ memcached ) ) ; return new CircuitBreaker ( $ storage , $ maxFailures , $ retryTimeout ) ; }
Creates a circuit breaker with same settings for all services using memcached instance as a backend

@param Memcached $memcached      instance of a connected Memcached object
@param int       $maxFailures    how many times do we allow service to fail before considering it offline
@param int       $retryTimeout   how many seconds should we wait before attempting retry

@return CircuitBreakerInterface
Creates a circuit breaker with same settings for all services using memcached instance as a backend