Unverified Commit 963d31b8 authored by André Silva's avatar André Silva Committed by GitHub
Browse files

node: spawn babe and grandpa as blocking tasks (#1292)

* node: spawn babe and grandpa as blocking tasks

* update to latest substrate
parent 1a0c1e9f
Pipeline #97915 passed with stages
in 28 minutes and 50 seconds
This diff is collapsed.
......@@ -358,7 +358,7 @@ macro_rules! new_full {
let (overseer, handler) = real_overseer(leaves, spawner)?;
service.spawn_essential_task("overseer", Box::pin(async move {
service.spawn_essential_task_handle().spawn("overseer", Box::pin(async move {
use futures::{pin_mut, select, FutureExt};
let forward = overseer::forward_events(overseer_client, handler);
......@@ -404,7 +404,7 @@ macro_rules! new_full {
};
let babe = babe::start_babe(babe_config)?;
service.spawn_essential_task("babe", babe);
service.spawn_essential_task_handle().spawn_blocking("babe", babe);
}
// if the node isn't actively participating in consensus then it doesn't
......@@ -464,7 +464,7 @@ macro_rules! new_full {
shared_voter_state,
};
service.spawn_essential_task(
service.spawn_essential_task_handle().spawn_blocking(
"grandpa-voter",
grandpa::run_grandpa_voter(grandpa_config)?
);
......
......@@ -389,7 +389,7 @@ macro_rules! new_full {
max_block_data_size,
}.build();
service.spawn_essential_task("validation-service", Box::pin(validation_service));
service.spawn_essential_task_handle().spawn("validation-service", Box::pin(validation_service));
handles.validation_service_handle = Some(validation_service_handle.clone());
......@@ -436,7 +436,7 @@ macro_rules! new_full {
};
let babe = babe::start_babe(babe_config)?;
service.spawn_essential_task("babe", babe);
service.spawn_essential_task_handle().spawn_blocking("babe", babe);
}
if matches!(role, Role::Authority{..} | Role::Sentry{..}) {
......@@ -470,7 +470,7 @@ macro_rules! new_full {
service.prometheus_registry(),
);
service.spawn_task("authority-discovery", authority_discovery);
service.spawn_task_handle().spawn("authority-discovery", authority_discovery);
}
}
......@@ -531,7 +531,7 @@ macro_rules! new_full {
shared_voter_state,
};
service.spawn_essential_task(
service.spawn_essential_task_handle().spawn_blocking(
"grandpa-voter",
grandpa::run_grandpa_voter(grandpa_config)?
);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment