2

I have searched about this but did not get an expected answer.

There is the same question asked but it applies to redis which can be solved by setting,

BROKER_TRANSPORT_OPTIONS = {'visibility_timeout': 3600*10} # 10 hours

I tried this but does not work as I got to know that this applies only to Redis and for rabitmq we have to use consumer_timeout. But not sure how can we set it up? or how to use it with rabitmq python/Django setting.

I am using amqp==2.6.1, celery==4.2.2, Python 3.8 Django==3.0.4. and CELERY_BROKER_TRANSPORT configurations,

CELERY_BROKER_TRANSPORT_OPTIONS = {
    'max_retries': 3,
    'interval_start': 0,
    'interval_step': 0.5,
    'interval_max': 3,
}

Running multiple celery shared_task at a time. In the middle, if the rabbitmq is down or any issues with the server. I can see celery re-running the same tasks over and over again indefinitely.

How to stop this re-running the celery task indefinitely?

codemastermind
  • 312
  • 1
  • 3
  • 19

0 Answers0