Author: jaliya
Date: Tue Jun 12 12:14:55 2007
New Revision: 546603

URL: http://svn.apache.org/viewvc?view=rev&rev=546603
Log:
Fixed the blocker AXIS2-2655
https://issues.apache.org/jira/browse/AXIS2-2655

We should only set the property Constants.RESPONSE_WRITTEN=true only if we are 
in the
server side. If it is in the client side we may not know whether we have 
received the response
in an async request/response case.

Modified:
    
webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/Constants.java
    
webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/transport/http/CommonsHTTPTransportSender.java

Modified: 
webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/Constants.java
URL: 
http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/Constants.java?view=diff&rev=546603&r1=546602&r2=546603
==============================================================================
--- 
webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/Constants.java 
(original)
+++ 
webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/Constants.java 
Tue Jun 12 12:14:55 2007
@@ -194,7 +194,7 @@
     public static final String TESTING_REPOSITORY = TESTING_PATH + "samples";
     public static final char SERVICE_NAME_SPLIT_CHAR = ':';
     public static final String SERVICE_GROUP_ID = "ServiceGroupId";
-    public static final String RESPONSE_WRITTEN = "CONTENT_WRITTEN";
+    public static final String RESPONSE_WRITTEN = "RESPONSE_WRITTEN";
     //To have a floag if the replyTo is not annon one
     public static final String DIFFERENT_EPR = "DIFFERENT_EPR";
 

Modified: 
webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/transport/http/CommonsHTTPTransportSender.java
URL: 
http://svn.apache.org/viewvc/webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/transport/http/CommonsHTTPTransportSender.java?view=diff&rev=546603&r1=546602&r2=546603
==============================================================================
--- 
webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/transport/http/CommonsHTTPTransportSender.java
 (original)
+++ 
webservices/axis2/trunk/java/modules/kernel/src/org/apache/axis2/transport/http/CommonsHTTPTransportSender.java
 Tue Jun 12 12:14:55 2007
@@ -209,7 +209,12 @@
                 }
             }
 
-            if (msgContext.getOperationContext() != null) {
+            /**
+             * We should only set the property Constants.RESPONSE_WRITTEN=true 
only if we are in the
+             * server side. If it is in the client side we may not know 
whether we have received the response
+             * in an async request/response case.
+             **/
+             if (msgContext.isServerSide()&& msgContext.getOperationContext() 
!= null) {
                 
msgContext.getOperationContext().setProperty(Constants.RESPONSE_WRITTEN,
                                                              
Constants.VALUE_TRUE);
             }
@@ -244,9 +249,9 @@
         if (transportInfo instanceof ServletBasedOutTransportInfo) {
             servletBasedOutTransportInfo =
                     (ServletBasedOutTransportInfo) transportInfo;
-            List customHheaders = (List) 
msgContext.getProperty(HTTPConstants.HTTP_HEADERS);
-            if (customHheaders != null) {
-                Iterator iter = customHheaders.iterator();
+            List customHeaders = (List) 
msgContext.getProperty(HTTPConstants.HTTP_HEADERS);
+            if (customHeaders != null) {
+                Iterator iter = customHeaders.iterator();
                 while (iter.hasNext()) {
                     Header header = (Header) iter.next();
                     if (header != null) {



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to