protected function createRedisDriver()
    {
        $serverArray    = $this->config['servers'];
        $persistent     = boolval($this->config['persistent']);
        $prefix         = trim($this->config['prefix']);
        $expireTime     = intval($this->config['lifetime']);

        if ($persistent) {
            foreach ($serverArray as $k => $v) {
                $v['persistent']    = true;
                $serverArray[$k]    = $v;
            }
        }

        $redisServer    = new RedisServer($serverArray);
        $redisStore     = new RedisStore($redisServer, $prefix);
        return new CacheSessionHandler($redisStore, $expireTime);
    }
protected function createRedisDriver()
    {
        $serverArray    = $this->config['servers'];
        $persistent     = boolval($this->config['persistent']);
        $prefix         = trim($this->config['prefix']);
        $expireTime     = intval($this->config['lifetime']);

        if ($persistent) {
            foreach ($serverArray as $k => $v) {
                $v['persistent']    = true;
                $serverArray[$k]    = $v;
            }
        }

        $redisServer    = new RedisServer($serverArray);
        $redisStore     = new RedisStore($redisServer, $prefix);
        return new CacheSessionHandler($redisStore, $expireTime);
    }
protected function createRedisDriver ( ) { $ serverArray = $ this -> config [ 'servers' ] ; $ persistent = boolval ( $ this -> config [ 'persistent' ] ) ; $ prefix = trim ( $ this -> config [ 'prefix' ] ) ; $ expireTime = intval ( $ this -> config [ 'lifetime' ] ) ; if ( $ persistent ) { foreach ( $ serverArray as $ k => $ v ) { $ v [ 'persistent' ] = true ; $ serverArray [ $ k ] = $ v ; } } $ redisServer = new RedisServer ( $ serverArray ) ; $ redisStore = new RedisStore ( $ redisServer , $ prefix ) ; return new CacheSessionHandler ( $ redisStore , $ expireTime ) ; }
create redis server driver

@return CacheSessionHandler
create redis server driver