Skip to content

Commit

Permalink
add docs to the Network's start function
Browse files Browse the repository at this point in the history
  • Loading branch information
divagant-martian committed Sep 6, 2022
1 parent 01cf480 commit 1e5694f
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion beacon_node/lighthouse_network/src/service/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -368,7 +368,11 @@ impl<AppReqId: ReqId, TSpec: EthSpec> Network<AppReqId, TSpec> {
Ok((network, network_globals))
}

// TODO: docs
/// Starts the network:
///
/// - Starts listening in the given ports.
/// - Dials boot-nodes and libp2p peers.
/// - Subscribes to starting gossipsub topics.
async fn start(&mut self, config: &crate::NetworkConfig) -> error::Result<()> {
let enr = self.network_globals.local_enr();
info!(self.log, "Libp2p Starting"; "peer_id" => %enr.peer_id(), "bandwidth_config" => format!("{}-{}", config.network_load, NetworkLoad::from(config.network_load).name));
Expand Down

0 comments on commit 1e5694f

Please sign in to comment.