From 789a896cca8ff9e6e6ab5cce409332dceeab7b7e Mon Sep 17 00:00:00 2001 From: "Frank.R.Wu" Date: Mon, 22 Nov 2021 15:23:50 +0800 Subject: [PATCH] feat: add CMDConf set -debug=all to set rootLogger as DEBUG --- src/main/java/org/bdware/server/CMHttpServer.java | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/main/java/org/bdware/server/CMHttpServer.java b/src/main/java/org/bdware/server/CMHttpServer.java index 9de4c3e..157d4bc 100644 --- a/src/main/java/org/bdware/server/CMHttpServer.java +++ b/src/main/java/org/bdware/server/CMHttpServer.java @@ -139,6 +139,10 @@ public class CMHttpServer { try { String[] classes = cmdConf.debug.split(","); for (String clz : classes) { + if ("all".equalsIgnoreCase(clz)) { + Configurator.setRootLevel(Level.DEBUG); + break; + } Configurator.setLevel(clz, Level.DEBUG); LOGGER.warn("set debug: " + clz); }