I can't find any information regarding retrying/error handling when using Predis.
$attempt = 0;
do {
try {
$value = $this->client->get($key);
return $value;
} catch (\Exception $ex) {
$this->client = new \Predis\Client();
}
} while(++attempt <= $MAX_RECONNECT_ATTEMPTS);
Is it make sense to reinitialize the Predis client, in case of server failure for example? Or is it handle by the client itself?