/** * {@inheritdoc} */ public function getConnectionByCommand(CommandInterface $command) { $slot = $this->strategy->getSlot($command); if (!isset($slot)) { throw new NotSupportedException("Cannot use '{$command->getId()}' over clusters of connections."); } $node = $this->distributor->getBySlot($slot); return $node; }