Skip to main content

Adds redis lock support to your Flask application

Project description

Example

from flask_redlock import RedisLock

redis_lock = RedisLock()
redis_lock.init_app(app)

with redis_lock.lock('something.lock', 3000, retry=10, interval=0.2) as lock:
    if not lock:
        return 'busy!'

    # Do your work here ...

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

Flask-Redlock-0.0.3.tar.gz (1.9 kB view details)

Uploaded Source

File details

Details for the file Flask-Redlock-0.0.3.tar.gz.

File metadata

  • Download URL: Flask-Redlock-0.0.3.tar.gz
  • Upload date:
  • Size: 1.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for Flask-Redlock-0.0.3.tar.gz
Algorithm Hash digest
SHA256 c0c94ff9db74afe4b214bddee65223a155b1907b9ed45284e0ee337e05f7c0e5
MD5 aa0c967236b8efebc133a797bb86d6fc
BLAKE2b-256 13cfc282a01e4918b327ebc861e88cabf05b5a11a902962cdd7bfc9a63c00d2c

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page