A
A
asmrnv7772016-09-28 16:44:16
Django
asmrnv777, 2016-09-28 16:44:16

How to deal with the periodic "falling off" Celery?

Hello colleagues.
I use celery in conjunction with Django. Here is the service config:

[Unit]
Description=celery daemon
After=network.target

[Service]
User=reviews
Group=reviews
WorkingDirectory=/opt/xxx/web/
Environment="PATH=/opt/xxx/bin"
ExecStart=/opt/xxx/bin/celery worker -A AppReviews

[Install]
WantedBy=multi-user.target

CELERY_BROKER_URL = 'redis://:[email protected]/0'
CELERY_RESULT_BACKEND = 'redis://:[email protected]/1'
CELERY_TASK_SERIALIZER = 'json'
CELERY_ACCEPT_CONTENT = ['json']

The scheme is as follows: when an object is saved to the database, a signal is triggered and, under certain conditions, a task is created for Celery. It works, but periodically the tasks stop being created (I monitor through flower). After restarting the service, everything starts working.
Actually, how to diagnose it and how to fix it?
PS It works through redis, it is more alive than all the living.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question