Function sn_node_manager::refresh_node_registry

source ·
pub async fn refresh_node_registry(
    node_registry: &mut NodeRegistry,
    service_control: &dyn ServiceControl,
    print_refresh_message: bool,
    full_refresh: bool,
) -> Result<()>
Expand description

Refreshes the status of the node registry’s services.

At a minimum, the refresh determines if each service is running. It does that by trying to find a process whose binary path matches the path of the binary for the service. Since each service uses its own binary, the path is a unique identifer. So you can know if any particular service is running or not.

A full refresh uses the RPC client to connect to the node’s RPC service to determine things like the number of connected peers.