Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我相信默认设置是任务历史记录在 1 天后被删除。我需要它在 30 天后过期。
是CELERY_TASK_RESULT_EXPIRES我要找的吗?还是我必须制作自定义凸轮?
CELERY_TASK_RESULT_EXPIRES
谢谢!
根据这个:
http://docs.celeryproject.org/en/latest/configuration.html?highlight=celery_task_result_expires#celery-task-result-expires
CELERY_TASK_RESULT_EXPIRES听起来正是您正在寻找的。确保检查注释,因为并非所有结果后端都受支持。有些还需要 celerybeat 才能运行。