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

EnableRetryWithBackoffTests is flaky #456

Closed
snicoll opened this issue Jul 14, 2024 · 1 comment
Closed

EnableRetryWithBackoffTests is flaky #456

snicoll opened this issue Jul 14, 2024 · 1 comment
Assignees
Labels
Milestone

Comments

@snicoll
Copy link
Member

snicoll commented Jul 14, 2024

EnableRetryWithBackoffTests.randomExponential:77 [Wrong periods: %s[1000, 1124]]
Expecting value to be true but was false
@snicoll snicoll added the task label Jul 14, 2024
@snicoll snicoll added this to the 2.0.8 milestone Jul 14, 2024
@artembilan
Copy link
Member

According to the report it turns out that our random logic in the ExponentialRandomBackOffPolicy:

next = (long) (next * (1 + r.nextFloat() * (getMultiplier() - 1)));

Accidentally ended up with with 1.
Therefore 1000 * 1 = 1000 😄

Fixing test respectively to include that possibility.

@artembilan artembilan self-assigned this Jul 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants