Skip to content

Commit

Permalink
Add tx hash caching TODO.
Browse files Browse the repository at this point in the history
  • Loading branch information
D-Stacks committed Nov 25, 2024
1 parent df48bf4 commit 08d45a9
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,9 @@ impl BlockBodyProcessor {
block.transactions.par_iter().enumerate().try_for_each(|(index, tx)| {
Self::validate_transaction_with_context(&(bbvc.clone()), tx, index as TransactionIndexType)?;
self.validate_transaction_in_isolation(tx)
// TODO: the tx hash may be cached from this point onward. Consider caching it here.
// i.e. something like: tx.finalize_hash(bbvc.storage_mass_activation)
// and then retrieve via tx.hash() in the future.
})
})
}
Expand Down

0 comments on commit 08d45a9

Please sign in to comment.