ox.scheduling.Schedule
See theSchedule companion object
case class Schedule(intervals: () => LazyList[FiniteDuration], initialDelay: Option[FiniteDuration])
Describes a schedule according to which ox.resilience.retry, repeat and schedule will invoke operations. A schedule is essentially a list of intervals, which are used to determine how long to wait before subsequent invocations of the operation.
Implementation note: the intervals lazy-list is lazy-evaluated itself, to avoid memory leaks when a schedule is captured as a value and used multiple times. The intervals list is re-created on every usage, which isn't optimal, but due to the small size (and gradual evaluation) of the list, should not cause any performance issues.
Value parameters
- initialDelay
-
The delay to wait before running the operation for the first time - if any.
- intervals
-
The intervals to use for the schedule.
Attributes
- Companion
- object
- Graph
-
- Supertypes
-
trait Serializabletrait Producttrait Equalsclass Objecttrait Matchableclass Any
Members list
In this article