Answer the question
In order to leave comments, you need to log in
Java logger configuration | How to do what I need?
Hello! I make a logger and it outputs everything in a strange way...
For example:
import java.util.logging.Level;
import java.util.logging.Logger;
class TestLogger {
private static final java.util.logging.Logger log = java.util.logging.Logger.getLogger(TestLogger.class.getName());
public static void main(String[] args) {
log.info("Application started!\nClass: " + TestLogger.class.getName());
}
}
дек 06, 2018 11:15:21 PM TestLogger main
INFO: Application started!
Class: TestLogger
[11:15:21] [TestLogger] INFO: Application started!
Class: TestLogger
And it's like this:[11:15:21] [TestLogger / main] INFO: Application started!
Class: TestLogger
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question