clean up code

This commit is contained in:
Dmytro Shvaika 2020-09-04 15:47:11 +03:00
parent f1b82c2d05
commit 9aff0692ae

View File

@ -114,10 +114,8 @@ public class TbRuleEngineProcessingStrategyFactory {
} catch (InterruptedException e) { } catch (InterruptedException e) {
throw new RuntimeException(e); throw new RuntimeException(e);
} }
if (multiplyPauseBetweenRetries && maxPauseBetweenRetries > 0) { if (multiplyPauseBetweenRetries && maxPauseBetweenRetries > pauseBetweenRetries) {
if (pauseBetweenRetries != maxPauseBetweenRetries) { pauseBetweenRetries = Math.min(maxPauseBetweenRetries, pauseBetweenRetries * 2);
pauseBetweenRetries = Math.min(maxPauseBetweenRetries, pauseBetweenRetries * pauseBetweenRetries);
}
} }
} }
return new TbRuleEngineProcessingDecision(false, toReprocess); return new TbRuleEngineProcessingDecision(false, toReprocess);