Companion for paritytech/substrate#14080 (#2526)

* Companion for paritytech/substrate#14080

* Update lockfile

* Update Polkadot

* Update Cargo.lock
This commit is contained in:
Aaro Altonen
2023-05-11 15:00:42 +03:00
committed by GitHub
parent 83899e2f16
commit ba75e8b84a
7 changed files with 320 additions and 288 deletions
@@ -24,6 +24,7 @@ use sc_network::{
NetworkService,
};
use sc_network::config::FullNetworkConfiguration;
use sc_network_common::{role::Roles, sync::message::BlockAnnouncesHandshake};
use sc_service::{error::Error, Configuration, NetworkStarter, SpawnTaskHandle};
use sc_utils::mpsc::tracing_unbounded;
@@ -33,6 +34,7 @@ use std::{iter, sync::Arc};
/// Build the network service, the network status sinks and an RPC sender.
pub(crate) fn build_collator_network(
config: &Configuration,
network_config: FullNetworkConfiguration,
spawn_handle: SpawnTaskHandle,
genesis_hash: Hash,
best_header: Header,
@@ -61,12 +63,11 @@ pub(crate) fn build_collator_network(
})
},
fork_id: None,
network_config: config.network.clone(),
network_config,
genesis_hash,
protocol_id,
metrics_registry: config.prometheus_config.as_ref().map(|config| config.registry.clone()),
block_announce_config,
request_response_protocol_configs: Vec::new(),
tx,
};