Uploaded image for project: 'Log4j 2'
  1. Log4j 2
  2. LOG4J2-2318

AsyncQueueFullMessageUtil causes unparsable message output

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 2.11.0
    • 3.0.0
    • Core
    • None

    Description

      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.

      Attachments

        Issue Links

          Activity

            People

              ckozak Carter Kozak
              ckozak Carter Kozak
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: