cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject svn commit: r1072931 - /cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/transform/TransformOutInterceptor.java
Date Mon, 21 Feb 2011 11:40:50 GMT
Author: sergeyb
Date: Mon Feb 21 11:40:50 2011
New Revision: 1072931

URL: http://svn.apache.org/viewvc?rev=1072931&view=rev
Log:
[CXF-3338] Ignoring out transform instructions in case of GET requests on the client side

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

Modified: cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/transform/TransformOutInterceptor.java
URL: http://svn.apache.org/viewvc/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/transform/TransformOutInterceptor.java?rev=1072931&r1=1072930&r2=1072931&view=diff
==============================================================================
--- cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/transform/TransformOutInterceptor.java
(original)
+++ cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/transform/TransformOutInterceptor.java
Mon Feb 21 11:40:50 2011
@@ -65,6 +65,9 @@ public class TransformOutInterceptor ext
     }
     
     public void handleMessage(Message message) {
+        if (!isHttpVerbSupported(message)) {
+            return;
+        }
         XMLStreamWriter writer = message.getContent(XMLStreamWriter.class);
         OutputStream out = message.getContent(OutputStream.class);
         
@@ -105,5 +108,8 @@ public class TransformOutInterceptor ext
         this.attributesToElements = value;
     }
     
+    protected boolean isHttpVerbSupported(Message message) {
+        return  isRequestor(message) && isGET(message) ? false : true;
+    }
     
 }



Mime
View raw message