cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ff...@apache.org
Subject svn commit: r1502119 - in /cxf/branches/2.7.x-fixes: ./ rt/transports/http/src/main/java/org/apache/cxf/transport/http/ systests/transports/src/test/java/org/apache/cxf/systest/http/ systests/transports/src/test/java/org/apache/cxf/systest/http/resources/
Date Thu, 11 Jul 2013 05:18:04 GMT
Author: ffang
Date: Thu Jul 11 05:18:03 2013
New Revision: 1502119

URL: http://svn.apache.org/r1502119
Log:
Merged revisions 1502096 via svnmerge from 
https://svn.apache.org/repos/asf/cxf/trunk

........
  r1502096 | ffang | 2013-07-11 11:29:12 +0800 (四, 11  7 2013) | 1 line
  
  [CXF-5114]CXF Client issue when try to handle session for One-Way Operation call
........

Modified:
    cxf/branches/2.7.x-fixes/   (props changed)
    cxf/branches/2.7.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java
    cxf/branches/2.7.x-fixes/systests/transports/src/test/java/org/apache/cxf/systest/http/ClientServerSessionTest.java
    cxf/branches/2.7.x-fixes/systests/transports/src/test/java/org/apache/cxf/systest/http/resources/SessionServer.xml

Propchange: cxf/branches/2.7.x-fixes/
------------------------------------------------------------------------------
  Merged /cxf/trunk:r1502096

Propchange: cxf/branches/2.7.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.

Modified: cxf/branches/2.7.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.7.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java?rev=1502119&r1=1502118&r2=1502119&view=diff
==============================================================================
--- cxf/branches/2.7.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java
(original)
+++ cxf/branches/2.7.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java
Thu Jul 11 05:18:03 2013
@@ -1528,7 +1528,13 @@ public abstract class HTTPConduit 
 
             InputStream in = null;
             // oneway or decoupled twoway calls may expect HTTP 202 with no content
-            if (isOneway(exchange) 
+
+            Message inMessage = new MessageImpl();
+            inMessage.setExchange(exchange);
+            updateResponseHeaders(inMessage);
+            inMessage.put(Message.RESPONSE_CODE, responseCode);
+
+            if (isOneway(exchange)
                 || HttpURLConnection.HTTP_ACCEPTED == responseCode) {
                 in = getPartialResponse();
                 if ((in == null) || !doProcessResponse(outMessage)) {
@@ -1561,11 +1567,7 @@ public abstract class HTTPConduit 
                 }
                 cachedStream = null;
             }
-            
-            Message inMessage = new MessageImpl();
-            inMessage.setExchange(exchange);
-            updateResponseHeaders(inMessage);
-            inMessage.put(Message.RESPONSE_CODE, responseCode);
+
             String charset = HttpHeaderHelper.findCharset((String)inMessage.get(Message.CONTENT_TYPE));
             String normalizedEncoding = HttpHeaderHelper.mapCharset(charset);
             if (normalizedEncoding == null) {

Modified: cxf/branches/2.7.x-fixes/systests/transports/src/test/java/org/apache/cxf/systest/http/ClientServerSessionTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.7.x-fixes/systests/transports/src/test/java/org/apache/cxf/systest/http/ClientServerSessionTest.java?rev=1502119&r1=1502118&r2=1502119&view=diff
==============================================================================
--- cxf/branches/2.7.x-fixes/systests/transports/src/test/java/org/apache/cxf/systest/http/ClientServerSessionTest.java
(original)
+++ cxf/branches/2.7.x-fixes/systests/transports/src/test/java/org/apache/cxf/systest/http/ClientServerSessionTest.java
Thu Jul 11 05:18:03 2013
@@ -227,11 +227,15 @@ public class ClientServerSessionTest ext
             BindingProvider bp = (BindingProvider)greeter;
             updateAddressPort(bp, PORT);
             bp.getRequestContext().put(BindingProvider.SESSION_MAINTAIN_PROPERTY, true);
+            
+            
                                              
             greeter.greetMeOneWay("Bonjour");
             
             String greeting = greeter.greetMe("Hello");
-            
+            if (greeting.indexOf(';') != -1) {
+                greeting = greeting.substring(0, greeting.indexOf(';'));
+            }
             assertNotNull("no response received from service", greeting);
             assertEquals("Hello Bonjour", greeting);
             

Modified: cxf/branches/2.7.x-fixes/systests/transports/src/test/java/org/apache/cxf/systest/http/resources/SessionServer.xml
URL: http://svn.apache.org/viewvc/cxf/branches/2.7.x-fixes/systests/transports/src/test/java/org/apache/cxf/systest/http/resources/SessionServer.xml?rev=1502119&r1=1502118&r2=1502119&view=diff
==============================================================================
--- cxf/branches/2.7.x-fixes/systests/transports/src/test/java/org/apache/cxf/systest/http/resources/SessionServer.xml
(original)
+++ cxf/branches/2.7.x-fixes/systests/transports/src/test/java/org/apache/cxf/systest/http/resources/SessionServer.xml
Thu Jul 11 05:18:03 2013
@@ -45,7 +45,11 @@
    
    <jaxws:endpoint 
        address="http://localhost:${testutil.ports.SessionServer}/SoapContext/GreeterPort"
-       implementor="org.apache.cxf.systest.http.GreeterSessionImpl"/> 
+       implementor="org.apache.cxf.systest.http.GreeterSessionImpl">
+       <jaxws:properties>
+           <entry key="org.apache.cxf.oneway.robust" value="true"/>
+       </jaxws:properties> 
+   </jaxws:endpoint>
         
         
    <jaxws:endpoint address="http://localhost:${testutil.ports.SessionServer}/Stateful1"
@@ -72,4 +76,4 @@
    <jaxws:endpoint address="http://localhost:${testutil.ports.SessionServer}/SpringBean"
        implementorClass="org.apache.cxf.systest.http.SpringAnnotationGreeterImpl"/>
          
-</beans>
\ No newline at end of file
+</beans>



Mime
View raw message