Description
We log misleading WARN log events from Log4j about message factories and unexpected formatting.
For example:
2016-05-29 18:21:46,712 main WARN The Logger com.example.foo was created with the message factory org.apache.logging.log4j.spi.MessageFactory2Adapter@46bc9802 and is now requested with the message factory org.apache.logging.log4j.m essage.StringFormatterMessageFactory@510e0dd2, which may create log events with unexpected formatting.
This is because in 2.6, AbstractMessageFactory implements MessageFactory instead of MessageFactory2.
This issue changes AbstractMessageFactory to implement MessageFactory2.
Attachments
Issue Links
- is duplicated by
-
LOG4J2-1416 Log4j 2.6 warning for a null message factory
- Resolved
-
LOG4J2-1404 log4j-slf4j-impl 2.6 is warning
- Closed
- relates to
-
LOG4J2-1180 Logger cache does not account for message factory
- Closed