You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by ru...@apache.org on 2005/08/15 14:04:00 UTC

svn commit: r232799 - in /webservices/axis/trunk/java/modules: core/src/org/apache/axis2/transport/http/ integration/test/org/apache/axis2/engine/

Author: ruchithf
Date: Mon Aug 15 05:03:48 2005
New Revision: 232799

URL: http://svn.apache.org/viewcvs?rev=232799&view=rev
Log:
Fixed the CommonsHTTPTransportSender to fix connection reset problem in the case of https and added a delay to the EchoRawXMLChunckedTest as a temp fix to the occational conn. reset issue in some platforms

Modified:
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/CommonsHTTPTransportSender.java
    webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/SimpleHTTPServer.java
    webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLChunckedTest.java

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/CommonsHTTPTransportSender.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/CommonsHTTPTransportSender.java?rev=232799&r1=232798&r2=232799&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/CommonsHTTPTransportSender.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/CommonsHTTPTransportSender.java Mon Aug 15 05:03:48 2005
@@ -226,7 +226,7 @@
         }
 
         public boolean isRepeatable() {
-            return false;
+            return true;
         }
 
         public byte[] writeBytes() throws AxisFault {
@@ -346,14 +346,14 @@
         //execuite the HtttpMethodBase - a connection manager can be given for handle multiple
         httpClient = new HttpClient();
         //hostConfig handles the socket functions..
-        HostConfiguration hostConfig = getHostConfiguration(msgContext, url);
+        //HostConfiguration hostConfig = getHostConfiguration(msgContext, url);
 
         // SO_TIMEOUT -- timeout for blocking reads
         httpClient.getHttpConnectionManager().getParams().setSoTimeout(60000);
         // timeout for initial connection
         httpClient.getHttpConnectionManager().getParams().setConnectionTimeout(60000);
 
-        PostMethod postMethod = new PostMethod();
+        PostMethod postMethod = new PostMethod(url.toString());
         postMethod.setPath(url.getFile());
 
         msgContext.setProperty(HTTP_METHOD, postMethod);
@@ -403,7 +403,7 @@
             }
         }
 
-        this.httpClient.executeMethod(hostConfig, postMethod);
+        this.httpClient.executeMethod(postMethod);
 
         if (postMethod.getStatusCode() == HttpStatus.SC_OK) {
             processResponse(postMethod, msgContext);

Modified: webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/SimpleHTTPServer.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/SimpleHTTPServer.java?rev=232799&r1=232798&r2=232799&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/SimpleHTTPServer.java (original)
+++ webservices/axis/trunk/java/modules/core/src/org/apache/axis2/transport/http/SimpleHTTPServer.java Mon Aug 15 05:03:48 2005
@@ -187,7 +187,7 @@
      */
     public EndpointReference replyToEPR(String serviceName) {
         return new EndpointReference("http://127.0.0.1:" + (embedded.getLocalPort()) +
-                "/axis/services/" +
+                "/axis2/services/" +
                 serviceName);
     }
 

Modified: webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLChunckedTest.java
URL: http://svn.apache.org/viewcvs/webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLChunckedTest.java?rev=232799&r1=232798&r2=232799&view=diff
==============================================================================
--- webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLChunckedTest.java (original)
+++ webservices/axis/trunk/java/modules/integration/test/org/apache/axis2/engine/EchoRawXMLChunckedTest.java Mon Aug 15 05:03:48 2005
@@ -136,6 +136,10 @@
                 Constants.TRANSPORT_HTTP,
                 false);
 
+        //Fix for the connection reset problem that we get once in a while
+        //with some linux distros
+        Thread.sleep(200);
+        
         OMElement result =
                 call.invokeBlocking(operationName.getLocalPart(),
                         payload);