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

feat: ISSUE-228 random - document as Jitter #376

Merged
Merged
Show file tree
Hide file tree
Changes from 2 commits
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
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -332,7 +332,7 @@ back off with an exponentially increasing wait period, to avoid two retries gett
lock step and both failing (a lesson learned from Ethernet). For this purpose, Spring
Retry provides `ExponentialBackoffPolicy`. Spring Retry also provides randomized versions
of delay policies that are quite useful to avoid resonating between related failures in a
complex system.
complex system by adding Jitter.
garyrussell marked this conversation as resolved.
Show resolved Hide resolved

## Listeners

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,8 @@

/**
* In the exponential case ({@link #multiplier()} > 0) set this to true to have the
* backoff delays randomized, so that the maximum delay is multiplier times the
* previous delay and the distribution is uniform between the two values.
* backoff delays randomized with Jitter, so that the maximum delay is multiplier
garyrussell marked this conversation as resolved.
Show resolved Hide resolved
* times the previous delay and the distribution is uniform between the two values.
* @return the flag to signal randomization is required (default false)
*/
boolean random() default false;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@
* that chooses a random multiple of the interval that would come from a simple
* deterministic exponential. The random multiple is uniformly distributed between 1 and
* the deterministic multiplier (so in practice the interval is somewhere between the next
* and next but one intervals in the deterministic case).
* and next but one intervals in the deterministic case). This is often referred to as
* Jitter.
garyrussell marked this conversation as resolved.
Show resolved Hide resolved
*
* This has shown to at least be useful in testing scenarios where excessive contention is
* generated by the test needing many retries. In test, usually threads are started at the
Expand Down