Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ExponentialDelayWithJitter ¶ added in v2.3.4
func ExponentialDelayWithJitter(ctx context.Context, attempt uint, baseDelay, maxDelay time.Duration) error
ExponentialDelayWithJitter is an exponential backoff strategy with jitter for retries. It calculates delay based on the attempt number, adds jitter, and sleeps for that duration, capped at maxDelay.
func LinearDelay ¶ added in v2.3.4
LinearDelay implements a linear backoff strategy for retries. It calculates delay based on the attempt number and sleeps for that duration, capped at maxDelay.
func NanoToTime ¶
NanoToTime converts an int64 nanoseconds to a time
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.