Skip to content
/ backoff Public

Package backoff implements a simple backoff algorithm, executing a function repeatedly until it returns a non-error result or the maximum allowed number of retries has been reached.

License

Notifications You must be signed in to change notification settings

heyts/backoff

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

backoff

Package backoff implements a simple backoff algorithm, executing a function repeatedly until it returns a non-error result or the maximum allowed number of retries has been reached.

The package implement two different strategies:

  • backoff.Linear: Attempts are made linearly, depending on maxRetries
  • backoff.Exponential: Attempts are made Exponentially, increasing the time between retries

About

Package backoff implements a simple backoff algorithm, executing a function repeatedly until it returns a non-error result or the maximum allowed number of retries has been reached.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages