Function libp2p_networking::network::spawn_network_node
source · pub async fn spawn_network_node<T: NodeType>(
config: NetworkNodeConfig<T>,
id: usize,
) -> Result<(NetworkNodeReceiver, NetworkNodeHandle<T>), NetworkError>
Expand description
Spawn a network node task task and return the handle and the receiver for it
§Errors
Errors if spawning the task fails