Disque\Connection\Manager::postprocessExecution PHP Method

postprocessExecution() protected method

Postprocess the command execution, eg. update node stats
protected postprocessExecution ( Disque\Command\CommandInterface $command, mixed $response ) : mixed
$command Disque\Command\CommandInterface
$response mixed
return mixed
    protected function postprocessExecution(CommandInterface $command, $response)
    {
        if ($command instanceof GetJob) {
            $this->updateNodeStats($command->parse($response));
            $this->switchNodeIfNeeded();
        }
        return $response;
    }