Skip to content

Support pending transaction score when saving and restoring txpool#8363

Merged
fab-10 merged 1 commit intobesu-eth:mainfrom
fab-10:txpool-save-restore-score
Mar 4, 2025
Merged

Support pending transaction score when saving and restoring txpool#8363
fab-10 merged 1 commit intobesu-eth:mainfrom
fab-10:txpool-save-restore-score

Conversation

@fab-10
Copy link
Copy Markdown
Contributor

@fab-10 fab-10 commented Feb 27, 2025

Signed-off-by: Fabio Di Fabio fabio.difabio@consensys.net

PR description

Fixed Issue(s)

Thanks for sending a pull request! Have you done the following?

  • Checked out our contribution guidelines?
  • Considered documentation and added the doc-change-required label to this PR if updates are required.
  • Considered the changelog and included an update if required.
  • For database changes (e.g. KeyValueSegmentIdentifier) considered compatibility and performed forwards and backwards compatibility tests

Locally, you can run these tests to catch failures early:

  • spotless: ./gradlew spotlessApply
  • unit tests: ./gradlew build
  • acceptance tests: ./gradlew acceptanceTest
  • integration tests: ./gradlew integrationTest
  • reference tests: ./gradlew ethereum:referenceTests:referenceTests

@fab-10 fab-10 force-pushed the txpool-save-restore-score branch 2 times, most recently from 2e151d5 to 7f57a5f Compare February 28, 2025 17:27
@fab-10 fab-10 marked this pull request as ready for review February 28, 2025 17:27
Copy link
Copy Markdown
Contributor

@macfarla macfarla left a comment

Choose a reason for hiding this comment

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

do we need to doc this? where does the score come from?

sbScore.append(line.charAt(i++));
}
final byte score =
sbScore.isEmpty() ? MAX_SCORE : Byte.parseByte(sbScore.toString());
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

maybe would be clearer to extract 878-884 to a method?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

done

Signed-off-by: Fabio Di Fabio <fabio.difabio@consensys.net>
@fab-10 fab-10 force-pushed the txpool-save-restore-score branch from 7f57a5f to 1e0586f Compare March 3, 2025 09:32
@fab-10
Copy link
Copy Markdown
Contributor Author

fab-10 commented Mar 3, 2025

do we need to doc this? where does the score come from?

Score for txpool come from this #7576, and there is no need to update doc, because not saving the score is basically a bug

@fab-10 fab-10 merged commit 74a1d8a into besu-eth:main Mar 4, 2025
43 checks passed
@fab-10 fab-10 deleted the txpool-save-restore-score branch March 4, 2025 08:24
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.

2 participants