From ba6660216ce40767df8f0a7a4c642aa6f2670182 Mon Sep 17 00:00:00 2001 From: wangruidong <940853815@qq.com> Date: Thu, 30 May 2024 19:00:29 +0800 Subject: [PATCH] perf: celery task log format --- apps/jumpserver/settings/libs.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apps/jumpserver/settings/libs.py b/apps/jumpserver/settings/libs.py index 445fa4202..b8859f7a8 100644 --- a/apps/jumpserver/settings/libs.py +++ b/apps/jumpserver/settings/libs.py @@ -165,8 +165,8 @@ CELERY_RESULT_SERIALIZER = 'pickle' CELERY_RESULT_BACKEND = CELERY_BROKER_URL CELERY_ACCEPT_CONTENT = ['json', 'pickle'] CELERY_RESULT_EXPIRES = 600 -CELERY_WORKER_TASK_LOG_FORMAT = '%(message)s' -CELERY_WORKER_LOG_FORMAT = '%(message)s' +CELERY_WORKER_TASK_LOG_FORMAT = '%(asctime).19s %(message)s' +CELERY_WORKER_LOG_FORMAT = '%(asctime).19s %(message)s' CELERY_TASK_EAGER_PROPAGATES = True CELERY_WORKER_REDIRECT_STDOUTS = True CELERY_WORKER_REDIRECT_STDOUTS_LEVEL = "INFO"