Use SpawnTaskHandles for spawning tasks in the tx pool (#8958)

* Remove futures-diagnose

* Use `SpawnTaskHandle`s for spawning tasks in the tx pool

* Box the spawner

* Fix tests

* Use the testing task executor
This commit is contained in:
Ashley
2021-06-01 16:28:03 +02:00
committed by GitHub
parent ac3c88fd34
commit 84e402389b
5 changed files with 12 additions and 31 deletions
+2 -2
View File
@@ -366,10 +366,10 @@ where
options: sc_transaction_graph::Options,
is_validator: txpool::IsValidator,
prometheus: Option<&PrometheusRegistry>,
spawner: impl SpawnNamed,
spawner: impl SpawnNamed + Clone + 'static,
client: Arc<Client>,
) -> Arc<Self> {
let pool_api = Arc::new(FullChainApi::new(client.clone(), prometheus));
let pool_api = Arc::new(FullChainApi::new(client.clone(), prometheus, spawner.clone()));
let pool = Arc::new(Self::with_revalidation_type(
options, is_validator, pool_api, prometheus, RevalidationType::Full, spawner
));