You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-user@logging.apache.org by Wi...@jeppesen.com on 2002/03/22 01:06:12 UTC

configureAndWatch bug


I've discovered what I consider a bug in Log4J version 1.1.3. I use the
PropertyConfigurator.configureAndWatch(configFile) to configure log4j. I have a
pretty minimal properties file that I use for configuration. It contains just 1
appender (ConsoleAppender) and a few categories that exist along one branch of
the hierarchy like so:

log4j.rootCategory=INFO, MAIN
log4j.appender.MAIN=org.apache.log4j.ConsoleAppender

log4j.category.X=DEBUG
log4j.category.X.Y=ERROR
log4j.category.X.Y.Z=INFO

There appears to be a problem if I *remove* or comment out the category X.Y.Z
line. If X.Y.Z contains logger.info("...") statements, when I delete the line
from the properties file, the change is not reflected in log4j after the default
 60 second wait time. Info log messages continually are sent to the log even
though only ERROR messages should be.

It appears to me that the problem lies in the hierarchy updates. A new Hierarchy
 object isn't getting generated when a change to the properties file is made, it
 is merely updated. If I change X.Y.Z to ERROR in the properties file,
everything works as expected, it is only a problem when I delete or comment out
X.Y.Z in log4j.properties.

Has anyone else experienced this behavior?
-wr



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>


org.w3c.Element exception with DOMConfigurator

Posted by "Edward Q. Bridges" <eb...@teachscape.com>.
when i compile a class that calls DOMConfigurator.configure(...)
i get a class not found exception cause the compiler is looking for org.w3c.Element.

i know i could just add the w3c classes to my jarpath, but why is it looking for these 
classes in my classpath???  shouldn't that be compiled code that does not need to know 
about the w3c classes?

thanks
--e--

--
Edward Q. Bridges
http://www.teachscape.com



--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>