相关疑难解决方法(0)

将所有celery任务的日志消息发送到单个文件

我想知道如何设置更具体的日志系统.我的所有任务都使用

logger = logging.getLogger(__name__)
Run Code Online (Sandbox Code Playgroud)

作为模块范围的记录器.

我希望celery登录到"celeryd.log"并将我的任务记录到"tasks.log",但我不知道如何让它工作.使用CELERYD_LOG_FILE来自django-celery我可以将所有与celeryd相关的日志消息路由到celeryd.log,但是没有在我的任务中创建的日志消息的跟踪.

python logging celery

64
推荐指数
2
解决办法
5万
查看次数

标签 统计

celery ×1

logging ×1

python ×1