Fixed the celery async mode (Bug 804788)
This commit is contained in:
Родитель
2a189f999f
Коммит
17b4d5b3b4
|
@ -308,7 +308,8 @@ class Command(BaseCommand):
|
|||
delete.add_task(delete_indexes, args=[to_remove])
|
||||
|
||||
# let's do it
|
||||
tree.apply_async()
|
||||
log('Running all indexation tasks')
|
||||
tree.apply_and_join()
|
||||
|
||||
# let's return the /_aliases values
|
||||
aliases = call_es('_aliases').json
|
||||
|
|
|
@ -1050,7 +1050,8 @@ CELERY_IGNORE_RESULT = True
|
|||
CELERY_SEND_TASK_ERROR_EMAILS = True
|
||||
CELERYD_LOG_LEVEL = logging.INFO
|
||||
CELERYD_HIJACK_ROOT_LOGGER = False
|
||||
CELERY_IMPORTS = ('lib.video.tasks', 'lib.metrics')
|
||||
CELERY_IMPORTS = ('lib.video.tasks', 'lib.metrics',
|
||||
'lib.es.management.commands.reindex')
|
||||
# We have separate celeryds for processing devhub & images as fast as possible
|
||||
# Some notes:
|
||||
# - always add routes here instead of @task(queue=<name>)
|
||||
|
|
Загрузка…
Ссылка в новой задаче