In the docs it says that the accuracy of reservoirRefreshInterval is +-5 seconds.
This is a problem because many APIs have limits with 1 second granularity, i.e. they allow x requests every second. So, we may be off their rate limit by nearly 5x.
Is there something I can do to make sure the reservoir is refreshed accurately every second? Should I be using a custom timeout + incrementReservoir function?
In the docs it says that the accuracy of
reservoirRefreshIntervalis +-5 seconds.This is a problem because many APIs have limits with 1 second granularity, i.e. they allow x requests every second. So, we may be off their rate limit by nearly 5x.
Is there something I can do to make sure the reservoir is refreshed accurately every second? Should I be using a custom timeout +
incrementReservoirfunction?