Registry / utility / sethvargo-go-retry

sethvargo-go-retry

JSON →
library0.2.4gogounverified

Go Retry provides flexible interfaces for retrying flaky or eventually consistent functions with customizable backoff strategies.

go get github.com/sethvargo/go-retry
INSTALL
IMPORT
SIG · SETHVARGO-GO-RETRY
S
sethvargo-go-retry
utilitygov0.2.4
harness data pending
Install & Compatibility
Where this runs

No compatibility data collected yet for this library.

Code
Verified usage

Verified import paths — ran on the pinned version, not inferred.

retry
github.com/sethvargo/go-retry

Retry an operation with Fibonacci backoff and a maximum of 3 retries.

import "github.com/sethvargo/go-retry" func main() { b := retry.NewFibonacci(1 * time.Second) err := retry.Do(context.Background(), retry.WithMaxRetries(3, b), func(ctx context.Context) error { // your operation return nil }) if err != nil { log.Fatal(err) } }
Debug
Known issues

No known issues recorded.

Upgrade
Version history
0.2.4latest on pkg.go.dev
Audit
Dependencies

No dependency data recorded yet.

Agent activity
6 hits · last 30 days
node
6
Resources
sethvargo-go-retry — go get sethvargo-go-retry · libregistry