Skip to content

Make maintain loop more reusable #16166

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

Open
mattsse opened this issue May 12, 2025 · 2 comments · May be fixed by #16177
Open

Make maintain loop more reusable #16166

mattsse opened this issue May 12, 2025 · 2 comments · May be fixed by #16177
Assignees
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

Comments

@mattsse
Copy link
Collaborator

mattsse commented May 12, 2025

Describe the feature

this is currently intended to be run as an endless future

pub async fn maintain_transaction_pool<N, Client, P, St, Tasks>(

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

@mattsse mattsse added C-enhancement New feature or request S-needs-triage This issue needs to be labelled labels May 12, 2025
@github-project-automation github-project-automation bot moved this to Backlog in Reth Tracker May 12, 2025
@mattsse mattsse added S-needs-design This issue requires design work to think about how it would best be accomplished A-tx-pool Related to the transaction mempool A-sdk Related to reth's use as a library and removed S-needs-triage This issue needs to be labelled labels May 12, 2025
@fantasyup
Copy link
Contributor

I can try if it's open to external contributors :)

@mattsse mattsse moved this from Backlog to In Progress in Reth Tracker May 12, 2025
@mattsse
Copy link
Collaborator Author

mattsse commented May 12, 2025

@fantasyup this one needs a bit more design work first

I'll have a few additional task coming up in a bit, also please feel free to reach out on tg @mattsse

@fgimenez fgimenez linked a pull request May 12, 2025 that will close this issue
@fgimenez fgimenez moved this from In Progress to In Review in Reth Tracker May 12, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
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
Projects
Status: In Review
Development

Successfully merging a pull request may close this issue.

3 participants