protected function _connection(array $config)
    {
        $redis = new \Redis;
        $host = empty($config['host']) ? self::DEFAULT_HOST : $config['host'];
        $port = empty($config['port']) ? self::DEFAULT_PORT : $config['port'];
        $timeout = empty($config['timeout']) ? self::DEFAULT_TIMEOUT : $config['timeout'];
        $connect = empty($config['persistent']) ? 'connect' : 'pconnect';
        $redis->$connect($host, $port, $timeout);
        return $redis;
    }
protected function _connection(array $config)
    {
        $redis = new \Redis;
        $host = empty($config['host']) ? self::DEFAULT_HOST : $config['host'];
        $port = empty($config['port']) ? self::DEFAULT_PORT : $config['port'];
        $timeout = empty($config['timeout']) ? self::DEFAULT_TIMEOUT : $config['timeout'];
        $connect = empty($config['persistent']) ? 'connect' : 'pconnect';
        $redis->$connect($host, $port, $timeout);
        return $redis;
    }
protected function _connection ( array $ config ) { $ redis = new \ Redis ; $ host = empty ( $ config [ 'host' ] ) ? self :: DEFAULT_HOST : $ config [ 'host' ] ; $ port = empty ( $ config [ 'port' ] ) ? self :: DEFAULT_PORT : $ config [ 'port' ] ; $ timeout = empty ( $ config [ 'timeout' ] ) ? self :: DEFAULT_TIMEOUT : $ config [ 'timeout' ] ; $ connect = empty ( $ config [ 'persistent' ] ) ? 'connect' : 'pconnect' ; $ redis -> $ connect ( $ host , $ port , $ timeout ) ; return $ redis ; }
Redis connect and return the redis instance

@param array $config The config
@return \Redis
Redis connect and return the redis instance