ceki 2004/11/09 02:30:02
Modified: src/java/org/apache/log4j AsyncAppender.java
Log:
AsyncAppender will correctly output messages with an associated
ObjectRenderer even in case the message changes.
Revision Changes Path
1.37 +4 -0
logging-log4j/src/java/org/apache/log4j/AsyncAppender.java
Index: AsyncAppender.java
===================================================================
RCS file:
/home/cvs/logging-log4j/src/java/org/apache/log4j/AsyncAppender.java,v
retrieving revision 1.36
retrieving revision 1.37
diff -u -r1.36 -r1.37
--- AsyncAppender.java 11 May 2004 09:38:23 -0000 1.36
+++ AsyncAppender.java 9 Nov 2004 10:30:02 -0000 1.37
@@ -94,6 +94,10 @@
// Get a copy of this thread's MDC.
event.initializeProperties();
+ // we need to get the rendered message in case it changes between now
+ // and handling by the worker thread
+ event.getRenderedMessage();
+
if (locationInfo) {
event.getLocationInformation();
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]