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