Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Set CACHEOPS_DEGRADE_ON_FAILURE to True
This commit is a follow-up to Incident 152 (and 95). Currently, the app fails with HTTP 5xx errors if the associated Redis cache is unreachable or cannot be used. This commit sets the `CACHEOPS_DEGRADE_ON_FAILURE` environment variable to be `True`. This env var instructs django-cacheops to wrap Redis calls in a try/except block and to handle connection errors and timeout errors gracefully, by writing a warning to the logs, rather than letting the relevant exception propagate up the stack. See: https://github.com/Suor/django-cacheops#setup https://github.com/Suor/django-cacheops/blob/master/cacheops/redis.py#L12-L22
- Loading branch information