How to restart Celery gracefully without delaying tasks

前端 未结 7 564
面向向阳花
面向向阳花 2020-12-24 07:14

We use Celery with our Django webapp to manage offline tasks; some of these tasks can run up to 120 seconds.

Whenever we make any code modifications, we need to rest

7条回答
  •  小蘑菇
    小蘑菇 (楼主)
    2020-12-24 07:41

    rm *.pyc
    

    This causes the updated tasks to be reloaded. I discovered this trick recently, I just hope there are no nasty side effects.

提交回复
热议问题