logging-log4j-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Curt Arnold (JIRA)" <j...@apache.org>
Subject [jira] Commented: (LOG4J2-19) Provide looser coupling of PatternConverters
Date Mon, 23 Jun 2008 03:16:44 GMT

    [ https://issues.apache.org/jira/browse/LOG4J2-19?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12607138#action_12607138
] 

Curt Arnold commented on LOG4J2-19:
-----------------------------------

The pattern parsing is a specialized form of configuration and should be consistent with the
overall approach to configuration, with support for the pattern syntax being a specialized
configurator.

Instead of getKeys(), it sounds like the default mapping of keys to classes could be done
with class attributes.

> Provide looser coupling of PatternConverters
> --------------------------------------------
>
>                 Key: LOG4J2-19
>                 URL: https://issues.apache.org/jira/browse/LOG4J2-19
>             Project: Log4j 2
>          Issue Type: Improvement
>          Components: Layouts
>            Reporter: Ralph Goers
>
> Currently, PatternLayout calls PatternParser which knows about the various PatternConverters,
many of which are imbedded in it. This makes it difficult for users to add their own Converters.

> In the logging framework I created each converter identified the conversion characters
it supported. Each PatternConverter was required to supply a getKeys() method that returned
this list. The equivalent of the PatternLayout contained an array of PatternConverters. During
initialization each of these would be called and the list of keys recorded along with the
associated converter. To add your own converter all that was necessary was to extend the class
and add your new keys to the list of recorded keys along with their converters. The base PatternLayout
would then take care of calling the correct converters as necessary.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


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


Mime
View raw message