Hacker News new | ask | show | jobs
by diggs 4109 days ago
What a coincidence, I found myself writing a little Go lib for exponential back off yesterday, and was wondering what the purpose of introducing jitter was and what effects it would have. I need it for interacting with the Twitter stream api and they're pretty clear that when they say exponential they mean it. But jitter looks very useful in some situations after reading this, so I added that to my lib as well...

It's here if anyone's interested it https://github.com/Diggs/go-backoff

1 comments

If we're talking about implementations in various languages, I might as well link to my capped backoff with jitter implementation for python.

https://github.com/ekimekim/pylibs/blob/master/libs/backoff....

(apologies for the long link, I keep all my one-file python libs in a single git repo for sanity. I think i've uploaded this one to pypi, where it's available under the name "backoff")

Hi Mike!

Thought you might be interested in my Elixir impl, though not as featureful: https://github.com/rickhull/backoff/blob/master/lib/backoff....

Example usage: https://github.com/rickhull/backoff/blob/master/examples/dem...