mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-09 20:11:09 +00:00
Add transaction pool to Aura and Babe import queue (#3225)
* Add transaction pool to babe import queue * Add transaction pool to Babe check header * Fix tests * Add tx pool to Aura import_queue * Fix tests, node-template * Add comments regarding unused _transaction_pool * Make tx pool optional in check_header
This commit is contained in:
@@ -95,14 +95,20 @@ construct_service_factory! {
|
||||
FullImportQueue = AuraImportQueue<
|
||||
Self::Block,
|
||||
>
|
||||
{ |config: &mut FactoryFullConfiguration<Self> , client: Arc<FullClient<Self>>, _select_chain: Self::SelectChain| {
|
||||
import_queue::<_, _, aura_primitives::sr25519::AuthorityPair>(
|
||||
{ |
|
||||
config: &mut FactoryFullConfiguration<Self>,
|
||||
client: Arc<FullClient<Self>>,
|
||||
_select_chain: Self::SelectChain,
|
||||
transaction_pool: Option<Arc<TransactionPool<Self::FullTransactionPoolApi>>>,
|
||||
| {
|
||||
import_queue::<_, _, aura_primitives::sr25519::AuthorityPair, _>(
|
||||
SlotDuration::get_or_compute(&*client)?,
|
||||
Box::new(client.clone()),
|
||||
None,
|
||||
None,
|
||||
client,
|
||||
config.custom.inherent_data_providers.clone(),
|
||||
transaction_pool,
|
||||
).map_err(Into::into)
|
||||
}
|
||||
},
|
||||
@@ -111,13 +117,14 @@ construct_service_factory! {
|
||||
>
|
||||
{ |config: &mut FactoryFullConfiguration<Self>, client: Arc<LightClient<Self>>| {
|
||||
let fprb = Box::new(DummyFinalityProofRequestBuilder::default()) as Box<_>;
|
||||
import_queue::<_, _, AuraAuthorityPair>(
|
||||
import_queue::<_, _, AuraAuthorityPair, TransactionPool<Self::FullTransactionPoolApi>>(
|
||||
SlotDuration::get_or_compute(&*client)?,
|
||||
Box::new(client.clone()),
|
||||
None,
|
||||
None,
|
||||
client,
|
||||
config.custom.inherent_data_providers.clone(),
|
||||
None,
|
||||
).map(|q| (q, fprb)).map_err(Into::into)
|
||||
}
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user