celery 启动显示警告信息“...whether broker connection retries are made during startup in Celery 6.0 and above...”
# celery作为一个单独项目运行,在settings文件中设置
broker_connection_retry_on_startup = True
# Celery作为第三方模块集成到项目中,在全局配置中添加
CELERY_BROKER_CONNECTION_RETRY_ON_STARTUP = True
修改配置后运行效果如下
单独运行 py 文件时遇到相同报错
# 修改版本
pip install celery==5.2.2
# 再次启动查看
celery --app celery_task worker -l info -P threads
celery --app celery_task worker -l info -P eventlet