Skip to content

Commit

Permalink
OpenConceptLab/ocl_issues#927 Redis clustering, fixing settings.py
Browse files Browse the repository at this point in the history
  • Loading branch information
rkorytkowski committed Aug 24, 2023
1 parent 4ad762b commit f8d3d76
Showing 1 changed file with 6 additions and 3 deletions.
9 changes: 6 additions & 3 deletions core/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -388,14 +388,16 @@
CELERY_RESULT_BACKEND_TRANSPORT_OPTIONS = {
'retry_policy': {
'timeout': 5.0,
}.update(RETRY_POLICY)
**RETRY_POLICY
}
}
CELERY_RESULT_EXTENDED = True
CELERY_RESULT_EXPIRES = 259200 # 72 hours

CELERY_BROKER_TRANSPORT_OPTIONS = {
'visibility_timeout': 259200, # 72 hours, the longest ETA
}.update(RETRY_POLICY)
**RETRY_POLICY
}

if REDIS_SENTINELS:
CELERY_RESULT_BACKEND = ''
Expand All @@ -419,7 +421,8 @@
CELERY_TASK_PUBLISH_RETRY = True
CELERY_TASK_PUBLISH_RETRY_POLICY = {
'retry_errors': None,
}.update(RETRY_POLICY)
**RETRY_POLICY
}

CELERY_ACCEPT_CONTENT = ['application/json']
CELERY_ONCE = {
Expand Down

0 comments on commit f8d3d76

Please sign in to comment.