logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jakob Homan" <jgho...@gmail.com>
Subject Setting arbitrary substitution values in log4j.xml?
Date Fri, 12 Dec 2008 00:45:40 GMT
I'm converting our project's log4j.properties to the log4j.xml in
order to take advantage of the automatic rolling compression.
Previously, we had lines such as:

ourapp.log.file= ourapp.log

Which were then substituted later on in such lines as

This allowed us to use the default values defined in the
log4j.properties file or to redefine them at run time.

My question is: how do I accomplish this within the log4j.xml?  I
can't find anywhere in the DTD for defining arbitrary values.  It
seems to work defining them as params within the root element, but it
generates the following warning:
log4j:WARN No such property [ourapp.log.dir] in org.apache.log4j.spi.RootLogger.
log4j:WARN No such property [ourapp.log.file] in

Can I find out if this is the correct way of doing this, and if so,
how I can turn off that warning, or can I find the correct way to do
this within log4j.xml?

Jakob Homan

To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org

View raw message