From fdf870c7794b9325f0f488000ba666273441934f Mon Sep 17 00:00:00 2001 From: weihongyang <1075331873@qq.com> Date: Wed, 29 Jun 2022 16:27:40 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E6=94=B9=E5=AE=9A=E6=97=B6?= =?UTF-8?q?=E4=BB=BB=E5=8A=A1=E7=9A=84log=E6=97=A5=E5=BF=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/java/com/cnbm/scheduletask/task/TestTask.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ym-schedule-task/src/main/java/com/cnbm/scheduletask/task/TestTask.java b/ym-schedule-task/src/main/java/com/cnbm/scheduletask/task/TestTask.java index 0eb2c1b..b14fe2b 100644 --- a/ym-schedule-task/src/main/java/com/cnbm/scheduletask/task/TestTask.java +++ b/ym-schedule-task/src/main/java/com/cnbm/scheduletask/task/TestTask.java @@ -1,5 +1,6 @@ package com.cnbm.scheduletask.task; +import lombok.extern.log4j.Log4j2; import org.slf4j.Logger; import org.slf4j.LoggerFactory; import org.springframework.stereotype.Component; @@ -9,12 +10,12 @@ import org.springframework.stereotype.Component; * @Date 2022/6/23 4:41 PM * @Version 1.0 */ +@Log4j2 @Component("testTask") public class TestTask implements ITask{ - private Logger logger = LoggerFactory.getLogger(getClass()); @Override public void run(String params){ - logger.debug("TestTask定时任务正在执行,参数为:{}", params); + log.info("TestTask定时任务正在执行,参数为:{}", params); } }