cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cschnei...@apache.org
Subject svn commit: r1190506 - /cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/AbstractLoggingInterceptor.java
Date Fri, 28 Oct 2011 19:12:47 GMT
Author: cschneider
Date: Fri Oct 28 19:12:46 2011
New Revision: 1190506

URL: http://svn.apache.org/viewvc?rev=1190506&view=rev
Log:
CXF-3888 Showing nicer class name and fixing checkstyle

Modified:
    cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/AbstractLoggingInterceptor.java

Modified: cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/AbstractLoggingInterceptor.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/AbstractLoggingInterceptor.java?rev=1190506&r1=1190505&r2=1190506&view=diff
==============================================================================
--- cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/AbstractLoggingInterceptor.java
(original)
+++ cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/AbstractLoggingInterceptor.java
Fri Oct 28 19:12:46 2011
@@ -24,6 +24,7 @@ import java.io.PrintWriter;
 import java.io.StringWriter;
 import java.net.URI;
 import java.util.logging.Level;
+import java.util.logging.LogRecord;
 import java.util.logging.Logger;
 
 import javax.xml.transform.OutputKeys;
@@ -170,7 +171,11 @@ public abstract class AbstractLoggingInt
             // Flushing the writer to make sure the message is written
             writer.flush();
         } else if (logger.isLoggable(Level.INFO)) {
-            logger.info(message);
+            LogRecord lr = new LogRecord(Level.INFO, message);
+            lr.setSourceClassName(logger.getName());
+            lr.setSourceMethodName(null);
+            lr.setLoggerName(logger.getName());
+            logger.log(lr);
         }
     }
     



Mime
View raw message