make more subsystems blocking, fix blocking subsystem spawning (#5133)

* make more subsystems blocking

* actually spawn blocking subsystems on their own threads
This commit is contained in:
Robert Habermeier
2022-03-16 01:41:20 -05:00
committed by GitHub
parent 2ead4ce12d
commit 5904ae418e
2 changed files with 4 additions and 4 deletions
@@ -594,7 +594,7 @@ pub(crate) fn impl_task_kind(info: &OverseerInfo) -> proc_macro2::TokenStream {
struct Blocking;
impl TaskKind for Blocking {
fn launch_task<S: SpawnNamed>(spawner: &mut S, task_name: &'static str, subsystem_name: &'static str, future: BoxFuture<'static, ()>) {
spawner.spawn(task_name, Some(subsystem_name), future)
spawner.spawn_blocking(task_name, Some(subsystem_name), future)
}
}