You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-dev@logging.apache.org by Ben Gill <Be...@t-mobile.co.uk> on 2002/12/12 13:46:46 UTC

inconsistency?

Hi,

The desired behaviour I wanted from log4j is to have ie. 2 appenders, and create loggers 1 and 2.  Logger 1 writes to appender 1, logger 2 to appender 2.

Attached are the test files (welcome to use as an example).  To achieve my goal, I had to remove the appenders from the root logger, and add them to the subclass loggers only...

removeAllAppenders seems to close the appender, removeAppender does not...

Anyhow, it works.  Code attached FYI

 <<EAILogger.java>>  <<Test.java>>  <<metrica.log>>  <<app.log>>  <<config>>