Happens with v. 1.2.9 and 1.2.12 Under Eclipse - Debug, all of a sudden log4j stopped working and I get on the console <<log4j:WARN No appenders could be found for logger (com.domain.test.TestSuite). log4j:WARN Please initialize the log4j system properly.>> Ok, I upgraded to log4j-1.3alpha-6.jar and got <<*** configurationOptionStr=null ** End of LogManager static initializer log4j:INFO Creating new logger [com.domain.test.TestSuite] in repository [default].>> but still no log.debug statements were honoured. The log4j.properties is in the usual place and has among others the following entries: log4j.appender.stdout=org.apache.log4j.ConsoleAppender log4j.logger.com.domain = DEBUG, stdout in org.apache.log4j.LogManager of the CVS HEAD, I saw the test for String debugProp = System.getProperty("log4j.debug"); but doing System.setProperty("log4j.debug", "true"); in TestSuite.main() is obviously too late if I do as the first statement in the class static Logger log = Logger.getLogger(TestSuite.class); Setting this "log4j.debug" variable to true in eclipe's Debug-Environment didn't make that more verbose either (I'm still hoping to see "**Start of LogManager static initializer"). Anyway, I went down and finally found the reason - the log4j.properties apparently also needs to be in a second place. What I would hope for that log4j would volunteer to say where it was searching in vane!
Created attachment 16403 [details] LogManager.java.patch This would certainly reduce the "config-problems" noise on the mailing list...
Patch doesn't apply correctly! Which version should I try to patch it with? I think this bug is no longer valid.