Skip to content
This repository has been archived by the owner on Jan 28, 2020. It is now read-only.

Commit

Permalink
Added compressor cache
Browse files Browse the repository at this point in the history
  • Loading branch information
George Schneeloch committed Nov 3, 2015
1 parent 3d66577 commit 247e6b5
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
7 changes: 6 additions & 1 deletion lore/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,10 @@ def get_var(name, default):
"lore_indexing": {
"BACKEND": "django.core.cache.backends.locmem.LocMemCache",
"TIMEOUT": get_var("LORE_INDEXING_CACHE_TIMEOUT", "60"),
}
},
"compressor": {
"BACKEND": "django.core.cache.backends.locmem.LocMemCache",
},
}

# Internationalization
Expand Down Expand Up @@ -215,6 +218,8 @@ def get_var(name, default):
)
COMPRESS_OFFLINE = get_var('LORE_COMPRESS_OFFLINE', False)
COMPRESS_ENABLED = get_var('LORE_COMPRESS_ENABLED', not DEBUG)
COMPRESS_CACHEABLE_PRECOMPILERS = ('text/jsx',)
COMPRESS_CACHE_BACKEND = 'compressor'

# Media and storage settings
IMPORT_PATH_PREFIX = get_var('LORE_IMPORT_PATH_PREFIX', 'course_archives/')
Expand Down
5 changes: 4 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,10 @@ celery==3.1.18
Django==1.8.5
django-appconf==1.0.1
django-bootstrap3==6.2.2
django-compressor==1.5

# Pin to develop branch for cache feature
git+https://github.com/django-compressor/django-compressor@5086fddb60d00ccb71a8883d4d0b40c6630d38e7#egg=django-compressor-dev==1.5-odl

django-debug-toolbar==1.3.2
django-elasticsearch-debug-toolbar==0.1.15
djangorestframework==3.2.2
Expand Down

0 comments on commit 247e6b5

Please sign in to comment.