dashboard/state_aggregator.py
async def list_nodes(self, *, option: ListApiOptions) -> dict:
        """List all node information from the cluster.

        Returns:
            {node_id -> node_data_in_dict}
            node_data_in_dict's schema is in NodeState
        """
        reply = await self._client.get_all_node_info(timeout=option.timeout)
        result = []
        for message in reply.node_info_list:
            data = self._message_to_dict(message=message, fields_to_decode=["node_id"])
            data = filter_fields(data, NodeState)
            result.append(data)

        # Sort to make the output deterministic.
        result.sort(key=lambda entry: entry["node_id"])
        return {d["node_id"]: d for d in islice(result, option.limit)}
List all node information from the cluster.

        Returns:
            {node_id -> node_data_in_dict}
            node_data_in_dict's schema is in NodeState
        
List all node information from the cluster.
List all node information from the cluster .
async def list_nodes(self, *, option: ListApiOptions) -> dict:
        reply = await self._client.get_all_node_info(timeout=option.timeout)
        result = []
        for message in reply.node_info_list:
            data = self._message_to_dict(message=message, fields_to_decode=["node_id"])
            data = filter_fields(data, NodeState)
            result.append(data)
        result.sort(key=lambda entry: entry["node_id"])
        return {d["node_id"]: d for d in islice(result, option.limit)}
async def list_nodes ( self , * , option : ListApiOptions ) -> dict : reply = await self . _client . get_all_node_info ( timeout = option . timeout ) result = [ ] for message in reply . node_info_list : data = self . _message_to_dict ( message = message , fields_to_decode = [ "node_id" ] ) data = filter_fields ( data , NodeState ) result . append ( data ) result . sort ( key = lambda entry : entry [ "node_id" ] ) return { d [ "node_id" ] : d for d in islice ( result , option . limit ) }
List all node information from the cluster.
List all node information from the cluster .
"""List all node information from the cluster.

        Returns:
            {node_id -> node_data_in_dict}
            node_data_in_dict's schema is in NodeState
        """ # Sort to make the output deterministic.
{node_id -> node_data_in_dict}
node_data_in_dict's schema is in NodeState
{ node_id - > node_data_in_dict } node_data_in_dict ' s schema is in NodeState
self
option
ListApiOptions