Giter Club home page Giter Club logo

python-redis-rate-limit's People

Contributors

areski avatar italorossi avatar kramarz avatar lamby avatar sevazhidkov avatar stefanyohansson avatar tlinhart avatar victor-torres avatar zhong-zendesk avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

python-redis-rate-limit's Issues

Add support for bulk increment usage

The rate limiter should have the ability to increase usage in bulk. This will allow the rate limit to assign different weights to different requests which will make the rate limiter more versatile.

This feature entails adding a Lua script to use incrby instead of incr and being able to pass in an argument to the script that will be used to increase the count.

Package name suggestion

It's always a good idea to have a short and concise name when importing the module.

I'm suggesting rlimiter:

from rlimiter import RateLimit, TooManyRequests

AWS ElastiCache support

redis_version = self._redis.info['redis_version'] is_supported = Version(str(redis_version)) >= Version('2.6.0')

This does not work on Amazon's ElastiCache as redis_version is a number, and Version() blows up with expected string or a byte-like object....

Support for per-client limits

Currently, a new rate limiter has to be created to have a separate limit per-client. Would you accept a PR to support per-client rate limits? I would add a check in the constructor here. If the max_requests is a dict, it will be treated as a mapping between client and max_requests for that client. Otherwise, it will be a global limit.

Please add a license to this project

Greetings,

I see on PyPI that this project is MIT-licensed. It would be nice to update this repository to reflect the same, if it truly is licensed under the MIT license.

Thank you for a great package.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.