Skip to content
Snippets Groups Projects
Commit 9e91dde8 authored by Alexander Pace's avatar Alexander Pace
Browse files

caching tweaks

parent fc182424
No related branches found
No related tags found
No related merge requests found
Pipeline #108428 passed
......@@ -143,6 +143,9 @@ try:
except:
AWS_ELASTICACHE_TIMEOUT = 30
# Set the middleware timeout equal to the cache timeout:
CACHE_MIDDLEWARE_SECONDS = AWS_ELASTICACHE_TIMEOUT
# Load modified caching middleware:
MIDDLEWARE = [
'core.middleware.maintenance.MaintenanceModeMiddleware',
......
......@@ -90,3 +90,4 @@ Events and associated data may change or be removed at any time.
if AWS_ELASTICACHE_ADDR:
CACHES['default']['KEY_PREFIX'] = '1'
CACHE_MIDDLEWARE_KEY_PREFIX = '1'
......@@ -46,3 +46,4 @@ if (DEBUG == True):
# Set elasticache prefix if the correct variables are set.
if AWS_ELASTICACHE_ADDR:
CACHES['default']['KEY_PREFIX'] = '3'
CACHE_MIDDLEWARE_KEY_PREFIX = '3'
......@@ -65,3 +65,4 @@ if (DEBUG == True):
# Set elasticache prefix if the correct variables are set.
if AWS_ELASTICACHE_ADDR:
CACHES['default']['KEY_PREFIX'] = '4'
CACHE_MIDDLEWARE_KEY_PREFIX = '4'
......@@ -90,3 +90,4 @@ to Playground or Production. Note, on this GraceDB instance:
if AWS_ELASTICACHE_ADDR:
CACHES['default']['KEY_PREFIX'] = '2'
CACHE_MIDDLEWARE_KEY_PREFIX = '2'
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment