Metadata-Version: 1.1
Name: nova-limits
Version: 0.5.2
Summary: Nova-specific rate-limit class for turnstile
Home-page: https://github.com/klmitch/nova_limits
Author: Kevin L. Mitchell
Author-email: kevin.mitchell@rackspace.com
License: Apache License (2.0)
Description: ============================================
        Keystone-specific Rate Limit Class for Turnstile
        ============================================
        
        This package provides the ``keystone_limits`` Python module, which
        contains the ``keystone_preprocess()`` preprocessor, the
        ``KeystoneClassLimit`` limit class, and the ``KeystoneTurnstileMiddleware``
        replacement middleware class, all for use with Turnstile.  These
        pieces work together to provide class-based rate limiting integration
        with keystone.  To use, you must configure the Turnstile middleware with
        the following configuration::
        
            [filter:turnstile]
            paste.filter_factory = turnstile.middleware:turnstile_filter
            turnstile = keystone_limits:KeystoneTurnstileMiddleware
            preprocess = keystone_limits:keystone_preprocess
            redis.host = <your Redis database host>
        
        Then, simply use the ``keystone_limits:KeystoneClassLimit`` rate limit class
        in your configuration.
        
        Using ``KeystoneClassLimit``
        ============================
        
        In addition to the other attributes provided by
        ``turnstile.limits:Limit``, the ``KeystoneClassLimit`` limit class
        provides one additional required argument: the ``rate_class``.  Each
        tenant is associated with a given rate-limit class through the Redis
        database.  (If no such association is present, the rate-limit class
        for a tenant is ``default``.)  Setting ``rate_class`` on
        ``KeystoneClassLimit`` restricts the limiting action to only those tenants
        in the given rate-limit class.
        
        
        Rate Classes
        ============
        
        In order to set which tenants belong to which limit class, you must
        insert this information into the redis database yourself. For example,
        in order to set a tenant with id '1234' to be part of the rate_class
        (set in the XML document mentioned above) called 'my_rate_class' you
        would have to:
        
        ``set limit-class:1234 my_rate_class``
        
Platform: UNKNOWN
Classifier: Development Status :: 4 - Beta
Classifier: Environment :: Web Environment
Classifier: Framework :: Paste
Classifier: Intended Audience :: System Administrators
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Programming Language :: Python
Classifier: Topic :: Internet :: WWW/HTTP :: WSGI :: Middleware
