public static void changeLogPath(String taskId){
Category cat = Logger.getRoot();
FileAppender fapp = (FileAppender) cat.getAppender("file");
if(fapp != null){
String filePath = fapp.getFile();
fapp.setFile(new File(filePath).getParent() + "/" + taskId + ".log");
fapp.activateOptions();
}
}
01-04
601
09-05
1万+
12-11
05-21
560
11-14
6457
05-25