Make maintain loop more reusable #16166
Labels
A-sdk
Related to reth's use as a library
A-tx-pool
Related to the transaction mempool
C-enhancement
New feature or request
S-needs-design
This issue requires design work to think about how it would best be accomplished
Describe the feature
this is currently intended to be run as an endless future
reth/crates/transaction-pool/src/maintain.rs
Line 117 in 82f4580
it contains the entire logic as a loop over messages
if the logic requires modification, then this is currently not easily doable.
so ideally we can encapsulate all this via dedicated type(s), for example:
drift monitoring, and reloading of dirty accounts
canon message processing
I think we can convert this logic into a few helper types so that the main logic loop just needs to do a select and handle the canon events
Additional context
No response
The text was updated successfully, but these errors were encountered: