Jitter factor #778
Replies: 3 comments 1 reply
-
I like the idea of a Jitter factor for retrying tests. What does the rest of the team think? Regarding your second comment: would you mind opening a separate discussion/issue for it as this is somewhat orthogonal to the Jitter factor discussion here? |
Beta Was this translation helpful? Give feedback.
-
I deleted now the second topic here and will create a new discussion for that. Regarding the Jitter factor, in the method adjustForJitter(...) you can see how it is implemented in Failsafe. |
Beta Was this translation helpful? Give feedback.
-
I also like the idea. I will open an issue. |
Beta Was this translation helpful? Give feedback.
-
I do not know if you will implement it and need it now, so I copied your RetryingTest classes into my test automation project and added an option to specify a jitter factor for the delay.
Because if tests run in parallel and they are all retried at nearly the same time then the result is more likely to fail again, especially for E2E tests.
But if the start for retries varies randomly then it is a bit more likely that tests eventually succeed.
For instance if delay is set to 10 seconds and a jitter factor of 0.5 then the delay will randomly vary between 5 and 15 seconds.
What also might good to provide options to use a backoff strategy like in Failsafe for Java.
Beta Was this translation helpful? Give feedback.
All reactions