From 0836261a055323923c5f01474cabd73462771bb0 Mon Sep 17 00:00:00 2001 From: wangxuanran <3055088966@qq.com> Date: Mon, 24 Jul 2023 10:46:45 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8E=A5=E5=8F=A3=E6=95=B0=E6=8D=AE=E5=90=8C?= =?UTF-8?q?=E6=AD=A5=E8=87=AA=E5=AE=9A=E4=B9=89sql=E6=89=93=E5=8D=B0cus=20?= =?UTF-8?q?=E4=BB=A5=E5=8F=8A=E5=8F=82=E6=95=B0map?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../aiyh/utils/response_deal/process/DataChangeProcess.java | 4 +++- .../aiyh/utils/response_deal/process/TypeChangeProcess.java | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/main/java/aiyh/utils/response_deal/process/DataChangeProcess.java b/src/main/java/aiyh/utils/response_deal/process/DataChangeProcess.java index bd57840..5b54b70 100644 --- a/src/main/java/aiyh/utils/response_deal/process/DataChangeProcess.java +++ b/src/main/java/aiyh/utils/response_deal/process/DataChangeProcess.java @@ -7,6 +7,7 @@ import aiyh.utils.response_deal.entity.ResponseConfigValueChange; import aiyh.utils.response_deal.exception.ResponseException; import aiyh.utils.response_deal.intfaces.DataChangeInterface; import aiyh.utils.response_deal.mapper.ConfigMapper; +import com.alibaba.fastjson.JSONObject; import org.apache.commons.lang3.StringUtils; import org.apache.log4j.Logger; @@ -33,7 +34,7 @@ public class DataChangeProcess { private static final ConfigMapper CONFIG_MAPPER = Util.getMapper(ConfigMapper.class); - public static final Logger logger = Util.getLogger(); + public static final Logger logger = Util.getLogger("json_util"); static { try { @@ -87,6 +88,7 @@ public class DataChangeProcess { if(!cusText.startsWith("select ")){ throw new ResponseException("When you select custom sql, you are not allowed to perform dangerous operations other than SELECT !!!"); } + logger.info(Util.logStr("cus sql : {}, params : {}", cusText, JSONObject.toJSONString(param))); String tempValue = CONFIG_MAPPER.executeCusQuerySql(cusText, param,new HashMap<>()); responseConfigValueChange.setJsonData(tempValue); return ""; diff --git a/src/main/java/aiyh/utils/response_deal/process/TypeChangeProcess.java b/src/main/java/aiyh/utils/response_deal/process/TypeChangeProcess.java index d691497..5c88327 100644 --- a/src/main/java/aiyh/utils/response_deal/process/TypeChangeProcess.java +++ b/src/main/java/aiyh/utils/response_deal/process/TypeChangeProcess.java @@ -20,7 +20,7 @@ public class TypeChangeProcess { public static final Map> MODE_METHOD_MAP = new HashMap<>(); - public static final Logger logger = Util.getLogger(); + public static final Logger logger = Util.getLogger("json_util"); static { try {