BinaryExponentialBackoffStrategy

A BackoffStrategy that implements binary exponential backoff. It returns a delay between 0 and 2**c - 1 inclusive, where c is the attempt number (starting at 1 for the delay after the first attempt). c is clamped at cMax. The delay is scaled by scale milliseconds.

Constructors

Link copied to clipboard
constructor(cMax: Int, scale: Long)

Functions

Link copied to clipboard
open override fun getDelay(attempt: Int): Long

Returns the delay in milliseconds to wait for after the given transaction attempt number.