grammyjs / storages

Storage adapters for grammY sessions.
48 stars 24 forks source link

Exponential backoff for sleeps #136

Closed KnorpelSenf closed 1 year ago

KnorpelSenf commented 1 year ago

We should increase the time as the number of requests increases.

_Originally posted by @Satont in https://github.com/grammyjs/storages/pull/135#discussion_r1048348484_

Most likely, it's a good idea to double the time to wait with each attempt, capped at one hour.