retry

package
v0.18.0 Latest Latest
Warning

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

Go to latest
Published: Dec 15, 2025 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Sleep

func Sleep(ctx context.Context, d time.Duration) error

Sleep is the equivalent of gax.Sleep without the need for the dependency.

Types

type Retryer

type Retryer struct {
	// contains filtered or unexported fields
}

Retryer is a retryer for HTTP requests.

func New

func New() *Retryer

New returns a new Retryer with the default backoff strategy.

func (*Retryer) Retry

func (r *Retryer) Retry(status int, err error) (time.Duration, bool)

Retry determines if a request should be retried.

Jump to

Keyboard shortcuts

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