You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@logging.apache.org by "Carter Kozak (Jira)" <ji...@apache.org> on 2021/12/25 16:47:00 UTC
[jira] [Created] (LOG4J2-3289) log4j-to-slf4j should not re-format the result of Message.getFormattedMessage
Carter Kozak created LOG4J2-3289:
------------------------------------
Summary: log4j-to-slf4j should not re-format the result of Message.getFormattedMessage
Key: LOG4J2-3289
URL: https://issues.apache.org/jira/browse/LOG4J2-3289
Project: Log4j 2
Issue Type: Bug
Components: SLF4J Bridge
Affects Versions: 2.17.0
Reporter: Carter Kozak
Fix For: 2.17.1
Both the formatted message result (for the configured MessageFactory) and the parameter array are passed to slf4j, such that slf4j attempts to format the already formatted result:
[https://github.com/apache/logging-log4j2/blob/20f9a97dbe5928c3b5077bcdd2a22ac92e941655/log4j-to-slf4j/src/main/java/org/apache/logging/slf4j/SLF4JLogger.java#L226-L256]
Caught a similar issue while reviewing this change, but realized it also applies to the slf4j bridge: [https://github.com/apache/logging-log4j2/pull/653#discussion_r775083351]
--
This message was sent by Atlassian Jira
(v8.20.1#820001)