Hi,
I'm trying to use log4j and commons-logging in the simplest app and I
get the infamous
log4j:WARN No appenders could be found for logger
(org.stockstats.tools.UpdateSymbols).
log4j:WARN Please initialize the log4j system properly.
In my classpath, I made sure I have commons-logging, log4j jars and my
log4j.properties file as follows and I even turned on log4j debugging
which claims that no log4j.properties file is found!
[fuzzmonkey:~/StockStats] novotny% java -Dlog4j.debug -cp
lib/log4j.properties:lib/commons-codec-1.3.jar:lib/commons-httpclient-3.1-rc1.jar:lib/commons-logging-1.0.4.jar:lib/log4j.properties:lib/log4j-1.2.11.jar:build/lib/stockstats-1.0.jar:.
org.stockstats.tools.Main
log4j: Trying to find [log4j.xml] using context classloader
[EMAIL PROTECTED]
log4j: Trying to find [log4j.xml] using
[EMAIL PROTECTED] class loader.
log4j: Trying to find [log4j.xml] using ClassLoader.getSystemResource().
log4j: Trying to find [log4j.properties] using context classloader
[EMAIL PROTECTED]
log4j: Trying to find [log4j.properties] using
[EMAIL PROTECTED] class loader.
log4j: Trying to find [log4j.properties] using
ClassLoader.getSystemResource().
log4j: Could not find resource: [null].
log4j:WARN No appenders could be found for logger
(org.stockstats.tools.UpdateSymbols).
log4j:WARN Please initialize the log4j system properly.
The only way I can get it to work is if I explicitly add
-Dlog4configuration=file:///tmp/log4j.properties to specify the file
location. I just cannot see why it can't find it in the classpath when I
specified it explicitly.
Thanks, Jason
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]