0

I want to have a celery worker and celery beat on the same process (dyno), however I want to limit the number of messages sent to RabbitMQ broker. Before implementing beat I have been using --without-heartbeat and it has been fine, but I wonder if this will still work when I add --beat to my procfile.

WORKER: celery worker --app=cworker.celery --autoscale=6,2 --beat --loglevel=info --without-mingle --without-gossip --without-heartbeat

Am I completely misunderstanding two separate elements?

Attack68
  • 4,437
  • 1
  • 20
  • 40
  • May I ask why you want to use `--without-heartbeat` and `--beat` in the same worker? – einverne Aug 27 '18 at 10:10
  • @einverne currently budget for only one worker, but want celery beat to process minimal scheduled tasks e.g. daily purge of expired task status message on redis result backend. But running --without-heartbeat, --without-gossip and --without-mingle to reduce the amount of messages passed to rabbitMQ broker. Any advice appreciated.. – Attack68 Aug 27 '18 at 10:20
  • Actually, I think you can reduce the task.delay() from your client. You can use the same worker to handle both task and period task with the default queue. You don't need to disable `--without-heartbeat` to prevent your worker to receive period task. – einverne Aug 27 '18 at 10:30

0 Answers0