I'm using the XMLSocketReceiver to receive log messages.  I want to append 
those messages to a JMS queue.  It kind of works.  
 
I don't want all messages generated in my receiver to end up in at my JMS 
appender, so I create a new logger repository (LoggerRepository, a.k.a. 
Hierarchy) and pass it to the XMLSocketReceiver.  Now, log messages generated 
by my receive program only go to the default logger (good).  HOWEVER, all log 
messages generated by the XMLSocketReceiver and XMLSocketNode classes (using 
the getLogger().debug()... paradigm) also go to the JMS queue appender.  
 
I'm guessing that this could be called a bug.  The XMLSocketReceiver should log 
to whatever repository is in place for the class itself, and should not be 
using the repository passed to the constructor.  The "passed in" repository 
should only be used for identifying appenders that should be used for the 
doPost() method.  (My hypothesis is based on the fact that few, if any, other 
Log4j internal classes take a repository for an argument, so, it goes that 
intenal classes should log using the repository that results from the 
LogManager's repository selector rather than a custom repository passed as a 
parameter to the constructor.)
 
I'd be interested in a short paragraph describing the log4j-1.3's new internal 
logging architecture since it looks like log4j is moving away from the LogLog 
helper.
 
Thanks for any help.
--Mark
 
(Scott, you name and e-mail address was on XMLSocketReceiver so you get a 
special "CC".)

Reply via email to