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

eval: split TestTransactionGroup from BlockEvaluator using TransactionGroupTester #5818

Open
wants to merge 8 commits into
base: master
Choose a base branch
from

Conversation

cce
Copy link
Contributor

@cce cce commented Nov 3, 2023

Summary

eval.TestTransactionGroup (and TestTransaction) need only read-only access to a few details about the next pending block. This introduces an interface TestEvalContext that is used by the transaction pool, so that there can be parallel TX backlog workers checking if transactions are well-formed and move them from the backlogQueue to the postVerificationQueue.

Test Plan

Updated TxHandler test that was checking Remember() vs Test() and counting metrics bumped by different kinds of err returns.

@cce cce added the Enhancement label Nov 3, 2023
@cce cce marked this pull request as ready for review October 4, 2024 18:31
Copy link

codecov bot commented Oct 4, 2024

Codecov Report

Attention: Patch coverage is 75.00000% with 8 lines in your changes missing coverage. Please review.

Project coverage is 56.20%. Comparing base (3b3b5ce) to head (24bb98b).
Report is 26 commits behind head on master.

Files with missing lines Patch % Lines
data/pools/transactionPool.go 55.55% 7 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master    #5818      +/-   ##
==========================================
+ Coverage   54.28%   56.20%   +1.91%     
==========================================
  Files         494      494              
  Lines       69936    69958      +22     
==========================================
+ Hits        37968    39318    +1350     
+ Misses      29246    27962    -1284     
+ Partials     2722     2678      -44     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

gmalouf
gmalouf previously approved these changes Oct 17, 2024
data/txHandler.go Show resolved Hide resolved
Copy link
Contributor

@jannotti jannotti left a comment

Choose a reason for hiding this comment

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

Seems like a good idea, I had small comments, but willing to approve as is.

data/txHandler.go Show resolved Hide resolved
data/pools/transactionPool.go Outdated Show resolved Hide resolved
@cce cce requested a review from jannotti November 8, 2024 14:09
@cce cce changed the title eval: split TestTransactionGroup from BlockEvaluator using TestEvalContext eval: split TestTransactionGroup from BlockEvaluator using TransactionGroupTester Nov 8, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants