|
@@ 90-92 (lines=3) @@
|
| 87 |
|
throw new CacheException('Redis connection failed. Check your configuration.'); |
| 88 |
|
} |
| 89 |
|
|
| 90 |
|
if (isset($config['password']) && !$this->redis->auth($config['password'])) { |
| 91 |
|
throw new CacheException('Redis authentication failed.'); |
| 92 |
|
} |
| 93 |
|
|
| 94 |
|
if (isset($config['database']) && $config['database'] > 0 && !$this->redis->select($config['database'])) { |
| 95 |
|
throw new CacheException('Redis select database failed.'); |
|
@@ 94-96 (lines=3) @@
|
| 91 |
|
throw new CacheException('Redis authentication failed.'); |
| 92 |
|
} |
| 93 |
|
|
| 94 |
|
if (isset($config['database']) && $config['database'] > 0 && !$this->redis->select($config['database'])) { |
| 95 |
|
throw new CacheException('Redis select database failed.'); |
| 96 |
|
} |
| 97 |
|
} catch (RedisException $e) { |
| 98 |
|
throw new CacheException('Redis connection refused (' . $e->getMessage() . ')'); |
| 99 |
|
} |