Skip to content
This repository has been archived by the owner on Oct 25, 2024. It is now read-only.

Does AddMevBundle need to use global pool mutex ? #7

Open
dmarzzz opened this issue Nov 22, 2022 · 2 comments
Open

Does AddMevBundle need to use global pool mutex ? #7

dmarzzz opened this issue Nov 22, 2022 · 2 comments

Comments

@dmarzzz
Copy link
Member

dmarzzz commented Nov 22, 2022

AddMevBundle surely needs to lock for atomicity of adding to the bundle pool (pool.mevBundles), but as far as I can tell it doesn't interact with the rest of the txpool so should be okay to use something like pool.bundleMu.Lock()? Happy to implement if so 😃

@Ruteri
Copy link
Collaborator

Ruteri commented Nov 22, 2022

I think it's a good idea!
Keep in mind pool.bundleFetcher is also accessed, but it can also be covered by the bundles-specific lock.

@dmarzzz
Copy link
Member Author

dmarzzz commented Nov 26, 2022

awesome ty for heads up! will try and get a PR out this coming week

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants