Skip to content
Django Cache Fallback - Multiple Cache Backend
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
cache_fallback
tests
.gitignore
.travis.yml
AUTHORS
LICENSE
MANIFEST.in
README.rst
requirements.txt
runtests.py
setup.cfg
setup.py
tox.ini

README.rst

Django Cache Fallback.

Info:This is the README file for Django Cache Fallback.
Author: Jakub S
https://travis-ci.org/Kub-AT/django-cache-fallback.svg?branch=master

PURPOSE

Allows you to set fallback cache backend (multiple cache backend). The data is not shared between cache backends. Example: Memcached is not available, backend switch to fallback. Site may slow down (cache have to be set) but will not rise an error (watch your logs)

INSTALLATION

pip install django-cache-fallback
INSTALLED_APPS = (
   ...
   'cache_fallback',
)

USAGE

Usage example PyLibMCCache + LocMemCache

CACHES = {
    'default': {
        'BACKEND': 'cache_fallback.FallbackCache',
    },

    'main_cache': {
        'BACKEND': 'django.core.cache.backends.memcached.MemcachedCache',
        'LOCATION': '/tmp/memcached.sock',
        'TIMEOUT': 500,
    },
    'fallback_cache': {
        'BACKEND': 'django.core.cache.backends.locmem.LocMemCache',
        'LOCATION': 'unique'
    }

}
You can’t perform that action at this time.