-
Notifications
You must be signed in to change notification settings - Fork 523
testing: update pingpong transaction sending logic #2747
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
Merged
tsachiherman
merged 34 commits into
algorand:master
from
tsachiherman:tsachi/fixmasterpingpong3
Aug 16, 2021
Merged
testing: update pingpong transaction sending logic #2747
tsachiherman
merged 34 commits into
algorand:master
from
tsachiherman:tsachi/fixmasterpingpong3
Aug 16, 2021
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…ent transactions.
AlgoStephenAkiki
approved these changes
Aug 16, 2021
Merged
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
This PR addresses several different behaviors of pingpong that doesn't align (anymore) with it's usage:
waitForNextRoundOrSleepmethod.pps.constructTxnmethod, as it's randomly select source/destination. instead, assemble the transaction explicitly.sendAsGroupwas much simplified by passing the explicit account. The non-possible error cases were removed.prepareApps, applications are compiled only once.sendersslice inprepareAppsshould have been reset. It wouldn't work correctly without it.instead of sending traffic, rebalancing and sending traffic again, we calculate the pessimistic remaining balance on each of the accounts. A background go-routine would update all these account. Once the balance on 20% of the accounts drops below the desired level, we attempt to rebalance them. In addition, in 50% of the cases, the pingpong would pick an account that has a low balance as the recipient of the transaction.
This model allow much longer runs without rebalancing actions takes place, resulting in a more precise and consistent transaction generation.
constructPaymentwas created to replace the libgoalConstructPayment. The difference is in the source of the getSuggestedParams`, which are refreshed by the monitoring go-routine. This reduces unneeded communication between pingpong and the node.Test Plan
Tested running against S1 network