Update sequence numbers for local account pool in transaction generator #15229
+81
−30
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This PR adds a new function called
update_sequence_numbers
in the transaction generator.The transaction emitter maintains a pool of accounts and uses these accounts to send transactions to the blockchain. The transaction emitter keeps track of the committed and expired transactions. The transaction emitter also fetches the latest sequence numbers for this pool of accounts and updates their local sequence numbers accordingly.
But for some workflow-based transaction types, the transaction generator maintains its own local pool of accounts, and doesn't use the account pool in transaction emitter for creating transactions. This means, when some transaction fails to execute, the transaction emitter doesn't have a way to update the sequence number for this account pool.
This PR adds the
update_sequence_numbers
function in the transaction generator. The transaction emitter can use this function to call the transaction generator with the latest fetched sequence numbers. Currently, this function implementation is left empty.How Has This Been Tested?
Key Areas to Review
Type of Change
Which Components or Systems Does This Change Impact?
Checklist