Skip to content
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

core/txpool/blobpool: simplify the drop txs logic in blobpool module. #30447

Closed
wants to merge 4 commits into from

Conversation

mask-pp
Copy link
Contributor

@mask-pp mask-pp commented Sep 17, 2024

  • Prealloc capacity for ids and nonces.
  • Simplify the logic of dropping offend transactions.

Copy link
Member

@karalabe karalabe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SGTM

@karalabe karalabe added this to the 1.14.9 milestone Sep 17, 2024
Copy link
Contributor

@holiman holiman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This change makes the code a bit smaller, that much I grant, but IMO not more simple.
The pre-alloc of ids and nonces makes it a bit more brittle, even though it's arguably slightly more performant.

I'd personally rather close this PR than merge it, but I'll leave it open for someone else to decide

@karalabe
Copy link
Member

The old code had a clearer intent, that's given. But I don't see anything wrong with the new one either and if it's ever so slightly less allocy, why not

@karalabe karalabe modified the milestones: 1.14.9, 1.14.10 Sep 17, 2024
@BigPoppas
Copy link

nice

@karalabe karalabe modified the milestones: 1.14.10, 1.14.11 Sep 27, 2024
@karalabe
Copy link
Member

In light of the latest broken release due to small refactors for the sake of refactoring, we've decided to reject such changes from now on as their value is semi-limited and they always post a danger to potentially breaking something unforeseen.

@karalabe karalabe closed this Sep 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants