Enum reool::config::BackoffStrategy[][src]

pub enum BackoffStrategy {
    NoBackoff,
    Constant {
        fixed: Duration,
        jitter: bool,
    },
    Incremental {
        jitter: bool,
    },
    IncrementalCapped {
        cap: Duration,
        jitter: bool,
    },
}
Expand description

A strategy for determining delays between retries

The pool has a fixed size and will try to create all the needed connections with infinite retries. This is the strategy to determine the delays between subsequent retries.

Variants

NoBackoff

Immediately retry

Constant

Retry always after a fixed interval. Maybe with some jitter.

Fields of Constant

fixed: Durationjitter: bool
Incremental

Use incremental backoff. Max is 10s. Maybe with some jitter.

Fields of Incremental

jitter: bool
IncrementalCapped

Use incremental backoff but not more than cap. Max is 10s. Maybe with some jitter. The maximum is always 10s even if cap is greater.

Fields of IncrementalCapped

cap: Durationjitter: bool

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.