mirror of
https://github.com/paradigmxyz/reth.git
synced 2026-01-30 09:38:24 -05:00
feat: add timestamp to pool update (#3833)
This commit is contained in:
committed by
GitHub
parent
e66464b14f
commit
9313eda6cc
@@ -266,6 +266,7 @@ pub async fn maintain_transaction_pool<Client, P, St, Tasks>(
|
||||
changed_accounts,
|
||||
// all transactions mined in the new chain need to be removed from the pool
|
||||
mined_transactions: new_mined_transactions.into_iter().collect(),
|
||||
timestamp: new_tip.timestamp,
|
||||
};
|
||||
pool.on_canonical_state_change(update);
|
||||
|
||||
@@ -331,6 +332,7 @@ pub async fn maintain_transaction_pool<Client, P, St, Tasks>(
|
||||
pending_block_base_fee,
|
||||
changed_accounts,
|
||||
mined_transactions,
|
||||
timestamp: tip.timestamp,
|
||||
};
|
||||
pool.on_canonical_state_change(update);
|
||||
}
|
||||
|
||||
@@ -257,6 +257,7 @@ where
|
||||
pending_block_base_fee,
|
||||
changed_accounts,
|
||||
mined_transactions,
|
||||
timestamp: _,
|
||||
} = update;
|
||||
let changed_senders = self.changed_senders(changed_accounts.into_iter());
|
||||
let block_info = BlockInfo {
|
||||
|
||||
@@ -402,6 +402,8 @@ pub struct CanonicalStateUpdate {
|
||||
pub changed_accounts: Vec<ChangedAccount>,
|
||||
/// All mined transactions in the block range.
|
||||
pub mined_transactions: Vec<H256>,
|
||||
/// Timestamp of the latest chain update
|
||||
pub timestamp: u64,
|
||||
}
|
||||
|
||||
impl fmt::Display for CanonicalStateUpdate {
|
||||
|
||||
Reference in New Issue
Block a user