You could increase the connection timeout on the stub. The
default is 2 min as far as i know. (Stub.setTimeout(...))
But i would highly recommend to make these calls asynchronous,
i.e. let them return immediately and ask for status or so in
a separate call.
Reason: the GT container has a limited number of service threads
that process incoming requests. This number is configurable and
incoming requests will be queued, but by doing a few calls to
your service and using up all available service threads the container
seems unresponsive to all other calls (like resource property queries,
requests to other services, requests to your service).
Martin
> Hi folks,
>
> I'm having a problem here, I did my own grid service, and it has an
> operation that executes almost 5 to 6 minutes
> and when I call this operation in my client I got this error:
> ERROR: ; nested exception is:
> java.net.SocketTimeoutException: Read timed out
> AxisFault
> faultCode:
> {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
> faultSubcode:
> faultString: java.net.SocketTimeoutException: Read timed out
> faultActor:
> faultNode:
> faultDetail:
> {
> http://xml.apache.org/axis/}stackTrace:java.net.SocketTimeoutException:
> Read
> timed out
> at java.net.SocketInputStream.socketRead0(Native Method)
> at java.net.SocketInputStream.read(SocketInputStream.java:129)
> at java.io.BufferedInputStream.fill(BufferedInputStream.java:218)
> at java.io.BufferedInputStream.read(BufferedInputStream.java:235)
> at
> org.apache.axis.transport.http.HTTPSender.readHeadersFromSocket(
> HTTPSender.java:545)
> at
> org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java
> :140)
> at org.apache.axis.strategies.InvocationStrategy.visit(
> InvocationStrategy.java:32)
> at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
> at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
> at org.apache.axis.client.AxisClient.invoke(AxisClient.java:165)
> at org.apache.axis.client.Call.invokeEngine(Call.java:2727)
> at org.apache.axis.client.Call.invoke(Call.java:2710)
> at org.apache.axis.client.Call.invoke(Call.java:2386)
> at org.apache.axis.client.Call.invoke(Call.java:2309)
> at org.apache.axis.client.Call.invoke(Call.java:1766)
> at
> br.topgrid.dcc.ufba.grid.services.afisdcc.afisDCCService.stubs.bindings.AfisDCCPortTypeSOAPBindingStub.matching
> (AfisDCCPortTypeSOAPBindingStub.java:683)
> at
> br.topgrid.dcc.ufba.grid.services.afisdcc.client.AfisDCCClient.matching(
> AfisDCCClient.java:169)
> at
> br.topgrid.dcc.ufba.grid.services.afisdcc.client.AfisDCCClient.main(
> AfisDCCClient.java:482)
>
> {http://xml.apache.org/axis/}hostname:mainha
>
> java.net.SocketTimeoutException: Read timed out
> at org.apache.axis.AxisFault.makeFault(AxisFault.java:101)
> at
> org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java
> :144)
> at org.apache.axis.strategies.InvocationStrategy.visit(
> InvocationStrategy.java:32)
> at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:118)
> at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
> at org.apache.axis.client.AxisClient.invoke(AxisClient.java:165)
> at org.apache.axis.client.Call.invokeEngine(Call.java:2727)
> at org.apache.axis.client.Call.invoke(Call.java:2710)
> at org.apache.axis.client.Call.invoke(Call.java:2386)
> at org.apache.axis.client.Call.invoke(Call.java:2309)
> at org.apache.axis.client.Call.invoke(Call.java:1766)
> at
> br.topgrid.dcc.ufba.grid.services.afisdcc.afisDCCService.stubs.bindings.AfisDCCPortTypeSOAPBindingStub.matching
> (AfisDCCPortTypeSOAPBindingStub.java:683)
> at
> br.topgrid.dcc.ufba.grid.services.afisdcc.client.AfisDCCClient.matching(
> AfisDCCClient.java:169)
> at
> br.topgrid.dcc.ufba.grid.services.afisdcc.client.AfisDCCClient.main(
> AfisDCCClient.java:482)
> Caused by: java.net.SocketTimeoutException: Read timed out
> at java.net.SocketInputStream.socketRead0(Native Method)
> at java.net.SocketInputStream.read(SocketInputStream.java:129)
> at java.io.BufferedInputStream.fill(BufferedInputStream.java:218)
> at java.io.BufferedInputStream.read(BufferedInputStream.java:235)
> at
> org.apache.axis.transport.http.HTTPSender.readHeadersFromSocket(
> HTTPSender.java:545)
> at
> org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java
> :140)
> ... 12 more
>
>
>
>
> I imagine this happens because the connection between the service and the
> client falls.
> How Do I increase the time of timeout?
>
>
> Regards.
>
> --
> "É este um mundo no qual devemos esconder nossas virtudes?"
> Willian Shakespeare
>
>
> ****************
> Wilson Júnior
> ****************
>