Falcon: Start a falcon rate limiter project

Created on 21 May 2017  路  8Comments  路  Source: falconry/falcon

We're looking for someone who would like to help us start a falcon rate limiting project. Depending on performance, etc. we may be able to simply build on top of https://limits.readthedocs.io/en/stable/. The implementation should be flexible enough to support additional algorithms beyond moving window (whether or not that is implemented via limits), such as token bucket.

enhancement needs contributor needs-decision

Most helpful comment

@kgriffs i would like to help out on this project. Do I need to present some proposal first, or create a MVP and make a PR?

All 8 comments

@kgriffs i would like to help out on this project. Do I need to present some proposal first, or create a MVP and make a PR?

@kgriffs will this ship as falcon feature or as an optional add-on?

@iUwej Probably as an add-on, but officially supported under the falconry umbrella.

@kgritesh It would be great if you could post a proposal here for community feedback.

@kgritesh any update on this ?

Since we haven't heard back from @kgritesh I'd be happy to get another volunteer to take this on and submit a proposal/POC.

Last comment by @ZelphirKaltstahl from the recently closed duplicate issue https://github.com/falconry/falcon/issues/969#issuecomment-379711610 :

Here is a project which does almost what I need: https://github.com/piotrmaslanka/falcon-ratelimit/blob/master/falconratelimit/ratelimit.py
Only that it returns HTTP code 200 even when there are too many requests. So I will fork it and try to fix that by setting the HTTP status code in the case of too many requests.
Edit 1:
Although the docs suggest, that I should already get the correct HTTP status code:

Note also that any exception (not just instances of HTTPError) can be caught, logged, and otherwise handled at the global level by registering one or more custom error handlers.

(http://falcon.readthedocs.io/en/stable/api/errors.html)
Maybe it is a bug in Falcon?

Recently authored by @zoltan-fedor: https://github.com/zoltan-fedor/falcon-limiter.

Was this page helpful?
0 / 5 - 0 ratings