-
Notifications
You must be signed in to change notification settings - Fork 119
feat(mempool): Add TxTracker support for handling temporary rejections #646
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
|
Could you add more information in the PR about the different effects of this PR? (i.e. new config that's available, the fact that we save a new file to disk, etc.) |
|
Could we add a system and integration test for this as well? |
|
I think we can also merge the logic in for #494 (comment) to make this fully functional. |
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #646 +/- ##
==========================================
+ Coverage 65.19% 65.27% +0.08%
==========================================
Files 317 320 +3
Lines 21612 21855 +243
==========================================
+ Hits 14090 14266 +176
- Misses 6358 6387 +29
- Partials 1164 1202 +38
🚀 New features to boost your workflow:
|
Description
This PR adds the tracking of priority transactions via
TxTracker, a local queue. This is populated by checking for temporary rejections (such as in the case of nonce gaps or underpriced tx), and adding it to theTxTrackerif that is the case. This is a separate state and worker that runs in a goroutine and periodically (initially after 10s) reevaluates its contents. No longer valid txs are dropped, newly valid txs are queued, and the rest remain in the local queue.If the home directory is configured and not blank, then the contents of the TxTracker are journaled and persisted to disk (by default in
~/.evmd/data/txpool/transactions.rlp). This is picked up between node restarts so that those local txs are not lost.This PR also adds the 4 new fields (
locals,no-locals,journal,rejournal) that is used byTxTrackertotoml.goand server flags underevm.mempool. TheconfigureEVMMempool/GetLegacyPoolConfighelpers have also been updated to make use of the toml and/or cli flag values.Closes: #500
Author Checklist
I have...
mainbranch