code: protected function pickNode()
      {
          $nodes       = $this->getNodes();
          $index = mt_rand(0, count($nodes) - 1);
          return array_keys($nodes)[$index];
      }
docs: Pick a random Node from the ring
  
  You can pick your friends, you can pick your node, but you can't pick your friend's node.  :)
  
  @return int
  @throws Exception