/**
* Creates a connect to Redis or Sentinel using the Predis\Client object. It proxies the connecting and converts
* specific client exceptions to more generic adapted ones in PSRedis
*
* @throws \PSRedis\Exception\ConnectionError
*/
public function connect()
{
try {
$this->predisClient = $this->predisClientFactory->createClient($this->clientType, $this->getPredisClientParameters());
$this->predisClient->connect();
$this->isConnected = $this->predisClient->isConnected();
} catch (ConnectionException $e) {
throw new ConnectionError($e->getMessage());
}
}