mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-26 22:47:56 +00:00
Fix import queue thread pool shutdown (#4929)
* Fix import queue thread pool shutdown * Make sure runtime is disposed before telemetry * Close channel istead of sending a message * Fixed test
This commit is contained in:
@@ -128,12 +128,14 @@ where
|
||||
|
||||
// we eagerly drop the service so that the internal exit future is fired,
|
||||
// but we need to keep holding a reference to the global telemetry guard
|
||||
// and drop the runtime first.
|
||||
let _telemetry = service.telemetry();
|
||||
|
||||
let f = service.fuse();
|
||||
pin_mut!(f);
|
||||
|
||||
runtime.block_on(main(f)).map_err(|e| e.to_string())?;
|
||||
drop(runtime);
|
||||
|
||||
Ok(())
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user