Пример #1
0
 /**
  * @return bool
  * @throws InvalidConfigException
  */
 public function testConnection()
 {
     try {
         $pong = $this->_connect->ping();
         if ($pong) {
             return true;
         } else {
             throw new InvalidConfigException('Pong failed! ' . $pong);
         }
     } catch (\Exception $e) {
         throw new InvalidConfigException('PING test Failed! Can`t connect to redis database, please check module and redis-connection settings!!!!');
     }
 }