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

ASF GitHub Bot commented on LOG4J2-2318:
----------------------------------------

GitHub user cakofony opened a pull request:

    https://github.com/apache/logging-log4j2/pull/166

    LOG4J2-2318: AsyncQueueFullMessageUtil logs to StatusLogger

    We no longer mutate messages when logging them out of order.

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/cakofony/logging-log4j2 LOG4J2-2318

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/logging-log4j2/pull/166.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #166
    
----
commit 518cdc7836f6c916c1cd1e1902257692f0b03f07
Author: Carter Kozak <ckozak@...>
Date:   2018-04-16T16:06:39Z

    LOG4J2-2318: AsyncQueueFullMessageUtil logs to StatusLogger
    
    We no longer mutate messages when logging them out of order.

----


> AsyncQueueFullMessageUtil causes unparsable message output
> ----------------------------------------------------------
>
>                 Key: LOG4J2-2318
>                 URL: https://issues.apache.org/jira/browse/LOG4J2-2318
>             Project: Log4j 2
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 2.11.0
>            Reporter: Carter Kozak
>            Assignee: Carter Kozak
>            Priority: Major
>
> AsyncQueueFullMessageUtil.transform modifies message format, dropping message 
> format and parameters, and concatenates text to the formatted output.
> It's a fairly common workflow to write a message implementation which outputs 
> json or some other structured data (e.g. request logs) which are parsed by 
> another mechanism. This often uses PatternLayout with pattern "%m%n". The 
> current implementation of AsyncQueueFullMessageUtil concatenates a warning to 
> the formatted message, which can break parsers.
> Proposal: Avoid modifying the message itself in favor of using 
> StatusLogger.warn when messages may be logged out of order.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to