Use json serialization in celery by default

This commit is contained in:
Adam Steele 2018-02-27 16:02:58 +00:00
parent 48a6bf56a6
commit c8415d1a25

View File

@ -274,6 +274,10 @@ if CELERY_BROKER_URL == 'django://':
CELERY_RESULT_BACKEND = 'redis://'
else:
CELERY_RESULT_BACKEND = CELERY_BROKER_URL
# default to json serialization only
CELERY_ACCEPT_CONTENT = ['json']
CELERY_TASK_SERIALIZER = 'json'
CELERY_RESULT_SERIALIZER = 'json'
########## END CELERY
{% endif %}