mirror of
https://github.com/sigp/lighthouse.git
synced 2026-03-09 11:41:51 +00:00
refactor: remove service_name (#8606)
Which issue # does this PR address? #8586 Please list or describe the changes introduced by this PR. Remove `service_name` from `TaskExecutor` Co-Authored-By: Abhivansh <31abhivanshj@gmail.com>
This commit is contained in:
@@ -118,7 +118,6 @@ pub async fn build_libp2p_instance(
|
||||
boot_nodes: Vec<Enr>,
|
||||
fork_name: ForkName,
|
||||
chain_spec: Arc<ChainSpec>,
|
||||
service_name: String,
|
||||
disable_peer_scoring: bool,
|
||||
inbound_rate_limiter: Option<InboundRateLimiterConfig>,
|
||||
) -> Libp2pInstance {
|
||||
@@ -127,7 +126,7 @@ pub async fn build_libp2p_instance(
|
||||
|
||||
let (signal, exit) = async_channel::bounded(1);
|
||||
let (shutdown_tx, _) = futures::channel::mpsc::channel(1);
|
||||
let executor = task_executor::TaskExecutor::new(rt, exit, shutdown_tx, service_name);
|
||||
let executor = task_executor::TaskExecutor::new(rt, exit, shutdown_tx);
|
||||
let custody_group_count = chain_spec.custody_requirement;
|
||||
let libp2p_context = lighthouse_network::Context {
|
||||
config,
|
||||
@@ -177,7 +176,6 @@ pub async fn build_node_pair(
|
||||
vec![],
|
||||
fork_name,
|
||||
spec.clone(),
|
||||
"sender".to_string(),
|
||||
disable_peer_scoring,
|
||||
inbound_rate_limiter.clone(),
|
||||
)
|
||||
@@ -187,7 +185,6 @@ pub async fn build_node_pair(
|
||||
vec![],
|
||||
fork_name,
|
||||
spec.clone(),
|
||||
"receiver".to_string(),
|
||||
disable_peer_scoring,
|
||||
inbound_rate_limiter,
|
||||
)
|
||||
@@ -266,16 +263,7 @@ pub async fn build_linear(
|
||||
let mut nodes = Vec::with_capacity(n);
|
||||
for _ in 0..n {
|
||||
nodes.push(
|
||||
build_libp2p_instance(
|
||||
rt.clone(),
|
||||
vec![],
|
||||
fork_name,
|
||||
spec.clone(),
|
||||
"linear".to_string(),
|
||||
false,
|
||||
None,
|
||||
)
|
||||
.await,
|
||||
build_libp2p_instance(rt.clone(), vec![], fork_name, spec.clone(), false, None).await,
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user