To remove all the pending tasks in Celery and RabbitMQ, you can follow these steps:
Stop Celery workers:
celery multi stop <worker_name> -A <app_name>
Purge the RabbitMQ queue:
celery -A <app_name> purge
This will remove all the messages from the RabbitMQ queue.
Restart the Celery workers:
celery multi start <worker_name> -A <app_name>
After following these steps, all the pending tasks in Celery and RabbitMQ should be removed.
Asked: 2023-03-29 11:00:00 +0000
Seen: 8 times
Last updated: Sep 12 '21