txHandler: fix TestTxHandlerAppRateLimiter#6075
Merged
algorandskiy merged 3 commits intoJul 26, 2024
Merged
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #6075 +/- ##
==========================================
- Coverage 56.29% 56.27% -0.03%
==========================================
Files 488 488
Lines 69581 69581
==========================================
- Hits 39172 39156 -16
- Misses 27752 27764 +12
- Partials 2657 2661 +4 ☔ View full report in Codecov by Sentry. |
jasonpaulos
reviewed
Jul 23, 2024
jasonpaulos
approved these changes
Jul 24, 2024
cce
approved these changes
Jul 26, 2024
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
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
As discovered in #5972 the TestTxHandlerAppRateLimiter had a typo.
This PR fixed it by crafting workload to make sure ARL in txHandler is getting actually called.
While debugging I noticed that
maxBucketSizeis set to 1 ifTxBacklogAppTxRateLimiterMaxSizeis less than 128 (number of buckets). Although this was not an issue in production due toTxBacklogAppTxRateLimiterMaxSize=1048576it would trigger eviction on each insert that makes ARL noop. SettingmaxBucketSizeto 2 as its min value makes it working in such extreme configuration.Test Plan
This is a test fix
Closes #5972