Disque\Connection\Manager::revealClusterFromHello PHP Метод

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

The HELLO response from a Disque node contains addresses of all other nodes in the cluster. We want to learn about them and save them, so that we can switch to them later, if needed.
private revealClusterFromHello ( Node $node )
$node Disque\Connection\Node\Node The current node
    private function revealClusterFromHello(Node $node)
    {
        $hello = $node->getHello();
        $revealedNodes = [];
        foreach ($hello[HelloResponse::NODES] as $node) {
            $id = $node[HelloResponse::NODE_ID];
            $revealedNode = $this->revealNodeFromHello($id, $node);
            // Update or set the node's priority as determined by Disque
            $priority = $node[HelloResponse::NODE_PRIORITY];
            $revealedNode->setPriority($priority);
            $revealedNodes[$id] = $revealedNode;
        }
        $this->nodes = $revealedNodes;
    }