You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4j-dev@logging.apache.org by "Frank Wißmann (JIRA)" <ji...@apache.org> on 2014/08/13 11:39:12 UTC
[jira] [Updated] (LOG4J2-774) NdcPatternConverter brakes Log4j
1.2.x layout
[ https://issues.apache.org/jira/browse/LOG4J2-774?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Frank Wißmann updated LOG4J2-774:
---------------------------------
Description:
In Log4j 1.2.17 NdcPatternConverter.format() returns an empty string "" or the stack messages separated by space "a b c" (NDC.DiagnosticContext.fullMessage).
The PatternLayout {{\[%20.20x\]}} results in
{noformat}[ ]{noformat}
or
{noformat}[ a b c]{noformat}
In Log4j 2.0.1 NdcPatternConverter.format() returns an unmodified Collection.toString() representation: "\[\]" for an empty collection or the collection separated by comma "\[a, b, c\]" (DefaultThreadContextStack.toString() and MutableThreadContextStack.toString()).
The PatternLayout {{\[%20.20x\]}} results in
{noformat}[ []]{noformat}
or
{noformat}[ [a, b, c]]{noformat}
was:
In Log4j 1.2.17 NdcPatternConverter.format() returns an empty string "" or the stack messages separated by space "a b c" (NDC.DiagnosticContext.fullMessage).
The PatternLayout \[%20.20x\] results in {{\[ \]}} or {{\[ a b c\]}}.
In Log4j 2.0.1 NdcPatternConverter.format() returns an unmodified Collection.toString() representation: "\[\]" for an empty collection or the collection separated by comma "\[a, b, c\]" (DefaultThreadContextStack.toString() and MutableThreadContextStack.toString()).
The PatternLayout \[%20.20x\] results in {{\[ \[\]\]}} or {{\[ \[a, b, c\]\]}}.
> NdcPatternConverter brakes Log4j 1.2.x layout
> ---------------------------------------------
>
> Key: LOG4J2-774
> URL: https://issues.apache.org/jira/browse/LOG4J2-774
> Project: Log4j 2
> Issue Type: Bug
> Components: Layouts
> Affects Versions: 2.0.1
> Reporter: Frank Wißmann
> Priority: Minor
> Labels: patch
> Fix For: 2.0.2
>
>
> In Log4j 1.2.17 NdcPatternConverter.format() returns an empty string "" or the stack messages separated by space "a b c" (NDC.DiagnosticContext.fullMessage).
> The PatternLayout {{\[%20.20x\]}} results in
> {noformat}[ ]{noformat}
> or
> {noformat}[ a b c]{noformat}
> In Log4j 2.0.1 NdcPatternConverter.format() returns an unmodified Collection.toString() representation: "\[\]" for an empty collection or the collection separated by comma "\[a, b, c\]" (DefaultThreadContextStack.toString() and MutableThreadContextStack.toString()).
> The PatternLayout {{\[%20.20x\]}} results in
> {noformat}[ []]{noformat}
> or
> {noformat}[ [a, b, c]]{noformat}
--
This message was sent by Atlassian JIRA
(v6.2#6252)
---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-dev-help@logging.apache.org