logging-log4j-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Remko Popma (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (LOG4J2-1296) Add MessageFactory that reuses a cached Message instance
Date Tue, 23 Feb 2016 14:54:18 GMT

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

Remko Popma commented on LOG4J2-1296:

 How so? This is the final step that hooks all the GC-free components together. If we cannot
reuse Messages then we cannot provide a GC-free execution path through Log4j and the whole
epic goes out the window. It is not as difficult as it sounds. 

> Add MessageFactory that reuses a cached Message instance
> --------------------------------------------------------
>                 Key: LOG4J2-1296
>                 URL: https://issues.apache.org/jira/browse/LOG4J2-1296
>             Project: Log4j 2
>          Issue Type: New Feature
>          Components: API
>    Affects Versions: 2.5
>            Reporter: Remko Popma
>            Assignee: Remko Popma
> As discussed in LOG4J2-1270, all current MessageFactory implementations create new temporary
Message objects. A GC-free configuration needs a different MessageFactory that reuses Message
> When Messages are being reused, async logging components need to be aware of this and
ensure the Message _content_  (rather than the Message instance itself) is passed to the background
thread. However, Messages that are not reusable should be passed to the background thread

This message was sent by Atlassian JIRA

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

View raw message