logging-log4j-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Curt Arnold <carn...@apache.org>
Subject Re: Layout experiment in sandbox
Date Sun, 29 Apr 2007 05:28:58 GMT

On Apr 28, 2007, at 11:37 PM, Paul Smith wrote:

> Only comment I can think of after looking at the code is that the  
> sub-layout elements (logger, priority, messageLayout etc) don't  
> quite make senses to me as 'layout's.  they are really  
> LayoutElements rather than a complete layout, but given one _might_  
> want to simply have a layout of only one element, your approach  
> does mean you could use a low-level layout.  It's just the names of  
> the classes I guess.

A traditional PatternLayout and PatternConverter functionally do the  
same thing, but there is a perceived difference.  They should have a  
consistent base interface so programatically they could be treated  
the same and share the same synchronization and composing services.   
I would not have a problem renaming the sub-layout elements to  
something like SourceFileNameConverter.  "PatternConverter" is over- 
specification since the same Converters could be used outside of a  

> Any reason to choose LogRecord as the name of the interface rather  
> than come up with a distinct name that doesn't use something from  
> the jul framework?  (there's no reason to use log4j LoggingEvent  
> either).
> Paul

Probably should be renamed since it did get annoying when both were  
in scope.  It would also be good to avoid conflict with LoggingEvent,  
so the obvious choices are LoggingRecord and LogEvent.  I'd prefer  
LoggingRecord.  I think it is probably best to choose an existing jul  
name for methods since the Java naming cops likely did a pretty  
through review and we can link to the platform Javadoc for  
elaboration when the concepts are identical.

I expect to add an interface along the lines of  
org.xml.sax.ErrorHandler which will be passed in to most non-trivial  
methods (including being added to the existing Layout methods).   
Probably call it something like ExceptionMonitor since it would not  
have semantics like the o.a.l.ErrorHandler.

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

View raw message