log4j.debug=true shows in the log how your log4j.properties are parsed and which properties may output i.e. a stack trace. I saw this once in my log when an appender tried to use a network port which was already occupied by a more early log4j.property element. I strongly recommend you to not hesitate and get the sources of log4j and have a look at the code in order to get what you want, because that is what experts/developers would have to do anyway. That is because such side effects as you see are by definition not seen by others or foreseen and hence for sure nowhere documented. It is however also true that with debuggers sometimes variables get initialize in a program and make a program running while not using a debugger may make the same program fail sometimes randomly. So if you're happy with the setup your log4j.properties enforce then it is time to switch log4j.debug=false and just use the capability now setup correctly of your log4j system. Then find your system work or fail and then in case of a failure look at logs and take a debugger.
Josef -----Ursprüngliche Nachricht----- Von: Danicela nutch [mailto:[email protected]] Gesendet: Dienstag, 18. Oktober 2011 16:05 An: [email protected] Betreff: log4j.debug=true impact on program Hi, I use Log4j for logging in a Nutch application. I noticed that I need to use log4j.debug=true in log4j.properties to get everything work properly, but I have many log4j useless lines in my log. The problem is that if I remove the log4j.debug=true, it changes the program as something is working wrong then. (Things like moving folders, defining properties -D etc.) What are the precise actions of the log4j.debug=true ? I need to know all the actions of this to know what treatment it modifies in my program. Thanks in advance.
