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

add a rety option to the step command #1585

Merged
merged 4 commits into from
Jan 13, 2025
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
ignore non-security error for jitter value
lewismarshall committed Jan 13, 2025
commit 97e8bd7673a2b5e4547ca96c527bfa7cf8e344d2
1 change: 1 addition & 0 deletions cmd/step/main.go
Original file line number Diff line number Diff line change
@@ -87,6 +87,7 @@ func calculateBackoff(minBackoff, maxJitter time.Duration) time.Duration {
if maxJitter <= 0 {
return minBackoff
}
//nolint:gosec // math/rand is acceptable here as jitter value is not used for security purposes
jitter := time.Duration(rand.Int63n(int64(maxJitter)))
return minBackoff + jitter
}