retry

package
v1.15.22 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 12, 2024 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

todo: there are more robust retry packages out there, discuss with team

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Retrier

type Retrier struct {
	Attempts   int
	Delay      time.Duration
	ExpBackoff bool
}

a Retrier can attempt an operation multiple times, based on some thresholds

func (Retrier) Do

func (r Retrier) Do(ctx context.Context, f func() error) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL