cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r830747 - /cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/interceptor/LoggingInInterceptor.java
Date Wed, 28 Oct 2009 20:05:03 GMT
Author: dkulp
Date: Wed Oct 28 20:05:03 2009
New Revision: 830747

URL: http://svn.apache.org/viewvc?rev=830747&view=rev
Log:
Precaution to make sure the logging triggers once.  (sometimes happens with faults)

Modified:
    cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/interceptor/LoggingInInterceptor.java

Modified: cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/interceptor/LoggingInInterceptor.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/interceptor/LoggingInInterceptor.java?rev=830747&r1=830746&r2=830747&view=diff
==============================================================================
--- cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/interceptor/LoggingInInterceptor.java
(original)
+++ cxf/branches/2.1.x-fixes/rt/core/src/main/java/org/apache/cxf/interceptor/LoggingInInterceptor.java
Wed Oct 28 20:05:03 2009
@@ -96,11 +96,15 @@
     } 
 
     private void logging(Message message) throws Fault {
+        if (message.containsKey(LoggingMessage.ID_KEY)) {
+            return;
+        }
         String id = (String)message.getExchange().get(LoggingMessage.ID_KEY);
         if (id == null) {
             id = LoggingMessage.nextId();
             message.getExchange().put(LoggingMessage.ID_KEY, id);
         }
+        message.put(LoggingMessage.ID_KEY, id);
         final LoggingMessage buffer 
             = new LoggingMessage("Inbound Message\n----------------------------", id);
 



Mime
View raw message