临时优化Client runWork
This commit is contained in:
@@ -113,4 +113,23 @@ public abstract class LoggingBaseHandler extends Handler {
|
||||
log.setParameters(new String[]{Thread.currentThread().getName(), traceid});
|
||||
}
|
||||
}
|
||||
|
||||
public static void initDebugLogConfig() {
|
||||
try {
|
||||
ByteArrayOutputStream out = new ByteArrayOutputStream();
|
||||
final PrintStream ps = new PrintStream(out);
|
||||
final String handlerName = LoggingFileHandler.LoggingConsoleHandler.class.getName(); //java.util.logging.ConsoleHandler
|
||||
ps.println("handlers = " + handlerName);
|
||||
ps.println(".level = FINEST");
|
||||
ps.println("jdk.level = INFO");
|
||||
ps.println("sun.level = INFO");
|
||||
ps.println("com.sun.level = INFO");
|
||||
ps.println("javax.level = INFO");
|
||||
ps.println(handlerName + ".level = FINEST");
|
||||
ps.println(handlerName + ".formatter = " + LoggingFormater.class.getName());
|
||||
LogManager.getLogManager().readConfiguration(new ByteArrayInputStream(out.toByteArray()));
|
||||
} catch (Exception e) {
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user