TokenBucketStorage primitive extracted from BasicDynamicTokenBucket
Summary: Extract the underlying primitive that powers BasicDynamicTokenBucket, as TokenBucketStroage. This abstraction speaks to "tokens" (instead of time) and allows for arbitrary borrowing. It also handles thread safety. This allows other bucket token based libraries to be created (eg. a Cooperative Scheduler) using the same primitive. API compatibility has been maintained with the existing classes. Reviewed By: yfeldblum, rohithmenon Differential Revision: D29522354 fbshipit-source-id: 010bd9caf3f9c3726621e87d23e5c564773424b7
Showing
This diff is collapsed.
Please register or sign in to comment