benkuly
08/18/2023, 2:39 PMOr
does not work anymore.
val schedule = Schedule.exponential<Throwable>(scheduleBase, scheduleFactor)
.or(Schedule.spaced(scheduleLimit))
.and(Schedule.doWhile { state.first() == RUN })
simon.vergauwen
08/28/2023, 7:31 AMor
with no transform
and combineDuration
argument.simon.vergauwen
08/28/2023, 7:34 AMval schedule = Schedule.exponential<Throwable>(scheduleBase, scheduleFacto)
.or(Schedule.spaced(scheduleLimit), transform = ::Pair) { a, b, -> minOf(a ?: ZERO, b ?: ZERO) }
.and(Schedule.doWhile { state.first() == RUN })