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

fix(DA): use expo backoff in retries #739

Merged
merged 22 commits into from
Apr 30, 2024

Conversation

danwt
Copy link
Contributor

@danwt danwt commented Apr 30, 2024

paritally adress #742

Also, make the health event stringer, and fix a typo in 1 log message

@danwt danwt requested a review from a team as a code owner April 30, 2024 11:03
// Delay returns the current delay. The subsequent delay will be increased by the growth factor up to the maximum.
func (b *Backoff) Delay() time.Duration {
ret := b.delay
b.delay = time.Duration(float64(b.delay) * b.growthFactor)

Check notice

Code scanning / CodeQL

Floating point arithmetic Note

Floating point arithmetic operations are not associative and a possible source of non-determinism
@danwt danwt self-assigned this Apr 30, 2024
Copy link
Contributor

@srene srene left a comment

Choose a reason for hiding this comment

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

I think the min and max delay of the backoff function could be a parameter in the config, but it can be a todo for another PR.

@danwt danwt linked an issue Apr 30, 2024 that may be closed by this pull request
3 tasks
@omritoptix omritoptix merged commit 848085f into main Apr 30, 2024
3 of 5 checks passed
@omritoptix omritoptix deleted the danwt/738-increase-threshold-for-unhealthy-da-events branch April 30, 2024 14:42
omritoptix pushed a commit that referenced this pull request Apr 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Clean up logs
3 participants