263 Lotus blogs updated hourly. Who will post next? Home | Blogs | Search | About 
 
Latest 7 Posts
Token bucket!
Sun, Jun 8th 2014 18
Top 10
Token bucket!
Sun, Jun 8th 2014 18




Recent Blog Posts
18
Token bucket!
Sun, Jun 8th 2014 11:10a   Bob Balaban
Greetings, geeks! I came across this problem on a project I'm doing: given a RESTful API on a web application server, how do you "throttle" calls so that a given authenticated user can only make a certain number of calls (N) per time interval (W), where both N and W are configurable. The solution I came up with is basically a “Token Bucket” with a sliding time window. What surprised me when I got something working was how easy it really was to implement. The context in whi




Created and Maintained by Yancy Lent - About - Planet Lotus Blog - Advertising - Mobile Edition