We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 146b99d commit cf60cc2Copy full SHA for cf60cc2
src/main/java/co/stateful/Atomic.java
@@ -141,10 +141,12 @@ public void run() {
141
);
142
}
143
++attempt;
144
- final long delay = (long) Tv.HUNDRED
145
- + (long) Atomic.RANDOM.nextInt(Tv.HUNDRED)
+ final long delay = Math.min(
+ TimeUnit.MINUTES.toMillis(1L),
146
+ (long) Tv.HUNDRED + (long) Atomic.RANDOM.nextInt(Tv.HUNDRED)
147
// @checkstyle MagicNumber (1 line)
- + (long) StrictMath.pow(5.0d, (double) attempt + 1.0d);
148
+ + (long) StrictMath.pow(5.0d, (double) attempt + 1.0d)
149
+ );
150
Logger.info(
151
this,
152
// @checkstyle LineLength (1 line)
0 commit comments