Django-db-mutex provides the ability to acquire a mutex lock from the database in Django.
For critical pieces of code that cannot overlap with one another, it is often necessary to acquire a mutex lock of some sort. Many solutions use a memcache lock strategy, however, this strategy can be brittle in the case of memcache going down or when an unconsistent hashing function is used in a distributed memcache setup.
If your application does not need a high performance mutex lock, Django DB Mutex does the trick. The common use case for Django DB Mutex is to provide the abilty to lock long-running periodic tasks that should not overlap with one another. Celery is the common backend for Django when scheduling periodic tasks.
To install the latest release, type:
pip install django-db-mutex
To install the latest code directly from source, type:
pip install git+git://github.com/ambitioninc/django-db-mutex.git
Full documentation is available at http://django-db-mutex.readthedocs.org
MIT License (see LICENSE)
1 year, 1 month ago passed
.. image:: https://readthedocs.org/projects/django-db-mutex/badge/?version=latest :target: https://django-db-mutex.readthedocs.io/en/latest/?badge=latest :alt: Documentation Status
<a href='https://django-db-mutex.readthedocs.io/en/latest/?badge=latest'> <img src='https://readthedocs.org/projects/django-db-mutex/badge/?version=latest' alt='Documentation Status' /> </a>
Project Privacy Level