We're throttling the requests to adapt to the server's policies. Our goal is to display the remaining requests and inform our users in case they've exceeded the limit. Instead of calling currentReservoir(), it'd be useful to provide a listener which returns the current reservoir's value when it's altered(both directions, i.e. either it increments or decrements). It's also a weight off our shoulders because we're no longer dependent on calling currentReservoir() manually.
We're throttling the requests to adapt to the server's policies. Our goal is to display the remaining requests and inform our users in case they've exceeded the limit. Instead of calling
currentReservoir()
, it'd be useful to provide a listener which returns the current reservoir's value when it's altered(both directions, i.e. either it increments or decrements). It's also a weight off our shoulders because we're no longer dependent on callingcurrentReservoir()
manually.What's your opinion on this idea?