@@ 45-54 (lines=10) @@ | ||
42 | $this->persistentConnect($redisConfig); |
|
43 | } |
|
44 | ||
45 | private function connect( array $redisConfig){ |
|
46 | $this->handler->connect( |
|
47 | $redisConfig['host'], |
|
48 | $redisConfig['port'], |
|
49 | $redisConfig['timeout'], |
|
50 | null, |
|
51 | $redisConfig['reconnectAttempt'] |
|
52 | ); |
|
53 | return $this->handler->select($redisConfig['dbIndex']); |
|
54 | } |
|
55 | ||
56 | private function persistentConnect( array $redisConfig){ |
|
57 | $this->handler->pconnect( |
|
@@ 56-65 (lines=10) @@ | ||
53 | return $this->handler->select($redisConfig['dbIndex']); |
|
54 | } |
|
55 | ||
56 | private function persistentConnect( array $redisConfig){ |
|
57 | $this->handler->pconnect( |
|
58 | $redisConfig['host'], |
|
59 | $redisConfig['port'], |
|
60 | $redisConfig['timeout'], |
|
61 | $redisConfig['persistentId'] |
|
62 | ); |
|
63 | return $this->handler->select($redisConfig['dbIndex']); |
|
64 | ||
65 | } |
|
66 | ||
67 | /** |
|
68 | * Fetch a value from the cache. |