cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject cxf git commit: [CXF-7123] Setting the exchange in chain complete property if it is 202 and no processing is required
Date Thu, 03 Nov 2016 12:40:52 GMT
Repository: cxf
Updated Branches:
  refs/heads/3.1.x-fixes 4649b456a -> cfe80c486


[CXF-7123] Setting the exchange in chain complete property if it is 202 and no processing
is required


Project: http://git-wip-us.apache.org/repos/asf/cxf/repo
Commit: http://git-wip-us.apache.org/repos/asf/cxf/commit/cfe80c48
Tree: http://git-wip-us.apache.org/repos/asf/cxf/tree/cfe80c48
Diff: http://git-wip-us.apache.org/repos/asf/cxf/diff/cfe80c48

Branch: refs/heads/3.1.x-fixes
Commit: cfe80c4862575df3d55c5052414eb7c31d129dab
Parents: 4649b45
Author: Sergey Beryozkin <sberyozkin@gmail.com>
Authored: Thu Nov 3 12:39:00 2016 +0000
Committer: Sergey Beryozkin <sberyozkin@gmail.com>
Committed: Thu Nov 3 12:40:30 2016 +0000

----------------------------------------------------------------------
 .../main/java/org/apache/cxf/transport/http/HTTPConduit.java | 1 +
 .../apache/cxf/systest/jaxrs/JAXRSClientServerBookTest.java  | 8 ++++++++
 2 files changed, 9 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf/blob/cfe80c48/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java
----------------------------------------------------------------------
diff --git a/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java
b/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java
index e5aa543..882ad5c 100644
--- a/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java
+++ b/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java
@@ -1636,6 +1636,7 @@ public abstract class HTTPConduit
                             cc.handleResponse(null, null);
                         }
                     }
+                    exchange.put("IN_CHAIN_COMPLETE", Boolean.TRUE);
                     exchange.setInMessage(inMessage);
                     return;
                 } 

http://git-wip-us.apache.org/repos/asf/cxf/blob/cfe80c48/systests/jaxrs/src/test/java/org/apache/cxf/systest/jaxrs/JAXRSClientServerBookTest.java
----------------------------------------------------------------------
diff --git a/systests/jaxrs/src/test/java/org/apache/cxf/systest/jaxrs/JAXRSClientServerBookTest.java
b/systests/jaxrs/src/test/java/org/apache/cxf/systest/jaxrs/JAXRSClientServerBookTest.java
index 8726685..e7dd9b5 100644
--- a/systests/jaxrs/src/test/java/org/apache/cxf/systest/jaxrs/JAXRSClientServerBookTest.java
+++ b/systests/jaxrs/src/test/java/org/apache/cxf/systest/jaxrs/JAXRSClientServerBookTest.java
@@ -778,6 +778,14 @@ public class JAXRSClientServerBookTest extends AbstractBusClientServerTestBase
{
     }
     
     @Test
+    public void testOnewayWebClient2() throws Exception {
+        WebClient client = WebClient.create("http://localhost:" + PORT + "/bookstore/oneway");
+        Response r = client.post(null);
+        assertEquals(202, r.getStatus());
+        assertFalse(r.getHeaders().isEmpty());
+    }
+    
+    @Test
     public void testBookWithSpace() throws Exception {
         WebClient client = WebClient.create("http://localhost:" + PORT + "/bookstore/").path("the
books/123");
         Book book = client.get(Book.class);


Mime
View raw message