I just recently ran into this issue, where I was getting the same exceptions. 
After tons of research, I tried disabling chunked HTTP requests on runtime
and it worked.  The server you may be trying to connect to, may not support
chunked requests. 
http://axis.apache.org/axis2/java/core/docs/http-transport.html

I hope this helps.



imorales wrote:
> 
> Hi all. I have a problem using Axis2. I generated a client Stub with
> wsdl2java and when I run the client stub to invoke the web service I´m
> getting a Read Time out exception:
> 
> ********************************************************************
> - Unable to sendViaPost to url[http://127.0.0.1:8181/services/serviceFTX]
> java.net.SocketTimeoutException: Read timed out
>         at java.net.SocketInputStream.socketRead0(Native Method)
>         at java.net.SocketInputStream.read(Unknown Source)
>         at java.io.BufferedInputStream.fill(Unknown Source)
>         at java.io.BufferedInputStream.read(Unknown Source)
>         at
> org.apache.commons.httpclient.HttpParser.readRawLine(HttpParser.java:77)
>         at
> org.apache.commons.httpclient.HttpParser.readLine(HttpParser.java:105)
>         at
> org.apache.commons.httpclient.HttpConnection.readLine(HttpConnection.java:1115)
>         at
> org.apache.commons.httpclient.MultiThreadedHttpConnectionManager$HttpConnectionAdapter.readLine(MultiThreadedHttpConnecti
> onManager.java:1373)
>         at
> org.apache.commons.httpclient.HttpMethodBase.readStatusLine(HttpMethodBase.java:1832)
>         at
> org.apache.commons.httpclient.HttpMethodBase.readResponse(HttpMethodBase.java:1590)
>         at
> org.apache.commons.httpclient.HttpMethodBase.execute(HttpMethodBase.java:995)
>         at
> org.apache.commons.httpclient.HttpMethodDirector.executeWithRetry(HttpMethodDirector.java:397)
>         at
> org.apache.commons.httpclient.HttpMethodDirector.executeMethod(HttpMethodDirector.java:170)
>         at
> org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:396)
>         at
> org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:346)
>         at
> org.apache.axis2.transport.http.AbstractHTTPSender.executeMethod(AbstractHTTPSender.java:520)
>         at
> org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:191)
>         at
> org.apache.axis2.transport.http.HTTPSender.send(HTTPSender.java:77)
>         at
> org.apache.axis2.transport.http.CommonsHTTPTransportSender.writeMessageWithCommons(CommonsHTTPTransportSender.java:327)
>         at
> org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:206)
>         at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:396)
>         at
> org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:374)
>         at
> org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:211)
>         at
> org.apache.axis2.client.OperationClient.execute(OperationClient.java:163)
> ********************************************************************
> 
> I modified the client stub setting the SO_TIMEOUT and CONNECTION_TIMEOUT
> but I´m getting the same error, this is the modification:
> 
> ********************************************************************
> _serviceClient.getOptions().setProperty(HTTPConstants.SO_TIMEOUT,new
> Integer(600000));
> _serviceClient.getOptions().setProperty(HTTPConstants.CONNECTION_TIMEOUT,new
> Integer(600000));
> ********************************************************************
> 
> I test the web service with SoapUI client and with the apache ODE
> sendSoap.bat and the web service it´s ok but with my client stub itsn´t. 
> 
> Any ideas about the problem, thanks in advance.
> 

-- 
View this message in context: 
http://old.nabble.com/unable-to-sendViaPost-to-url-...--Socket-Read-Time-out-problem-tp16939585p32501081.html
Sent from the Axis - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: java-user-unsubscr...@axis.apache.org
For additional commands, e-mail: java-user-h...@axis.apache.org

Reply via email to