Predis\Connection\Aggregate\SentinelReplication::retryCommandOnFailure PHP Метод

retryCommandOnFailure() приватный Метод

Retries the execution of a command upon server failure after asking a new configuration to one of the sentinels.
private retryCommandOnFailure ( Predis\Command\CommandInterface $command, string $method ) : mixed
$command Predis\Command\CommandInterface Command instance.
$method string Actual method.
Результат mixed
    private function retryCommandOnFailure(CommandInterface $command, $method)
    {
        $retries = 0;
        SENTINEL_RETRY:
        try {
            $response = $this->getConnection($command)->{$method}($command);
        } catch (CommunicationException $exception) {
            $this->wipeServerList();
            $exception->getConnection()->disconnect();
            if ($retries == $this->retryLimit) {
                throw $exception;
            }
            usleep($this->retryWait * 1000);
            ++$retries;
            goto SENTINEL_RETRY;
        }
        return $response;
    }