Module backoff

Source
Expand description

Helpers for retrying a fallible operation according to a backoff schedule.

Runner::run retries the specified operation according to the BackoffSchedule of the Runner. Users can customize the backoff behavior by implementing BackoffSchedule.

Structs§

Runner 🔒
A runner for a fallible operation, which retries on failure according to a BackoffSchedule.

Enums§

BackoffError 🔒
The type of error encountered while running a fallible operation.

Traits§

BackoffSchedule 🔒
A trait that specifies the parameters for retrying a fallible operation.
RetriableError 🔒
A trait for representing retriable errors.

Functions§

optionally_timeout 🔒
Wrap a Future with an optional timeout.