logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ceki Gülcü <c...@qos.ch>
Subject Re: Log4J PatternLayout
Date Wed, 02 Mar 2005 18:35:40 GMT

Yes, this is normal. (Log4j is just following what the JVM says the 
currently executing class is.)

Have you considered using naming your loggers after the class where they 
are located? In that case, the logger name will match the class name. As an 
initial consequence, you won't need the C converter at all. Second, if you 
also use per instance loggers instead of static ones, then the problem you 
are observing will go away. This was previously discussed several times on 
this list in some detail.


At 07:19 PM 3/2/2005, Yuriy Zubarev wrote:
>I use "C" conversion character in a pattern layout to get a class name 
>where the message is logged from. When I do logging from a method of an 
>abstract class I see the name of this abstract class in a log file, not 
>the class that extends it. Is it normal behaviour? How can I make it log 
>class names
>that extend the abstract class?

Ceki Gülcü

   The complete log4j manual: http://www.qos.ch/log4j/

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

View raw message