Added some config settings

Updated README
This commit is contained in:
Ilan Steemers
2015-06-17 19:14:20 +02:00
parent b28754de93
commit 2e81ba2858
4 changed files with 121 additions and 9 deletions
+16
View File
@@ -1,3 +1,5 @@
from multiprocessing import cpu_count
from django.apps import AppConfig
from django.conf import settings
@@ -6,6 +8,7 @@ class SessionAdminConfig(AppConfig):
name = 'django_q'
verbose_name = "Django Q"
"""
Sets the logging level for the app
"""
@@ -31,3 +34,16 @@ try:
SAVE_LIMIT = settings.Q_SAVE_LIMIT
except AttributeError:
SAVE_LIMIT = 100
try:
WORKERS = settings.Q_WORKERS
except AttributeError:
WORKERS = cpu_count()
"""
Turns compression on/off for task packages
"""
try:
COMPRESSED = settings.Q_COMPRESSED
except AttributeError:
COMPRESSED = False