Discussion:
Webservice client - ConnectionPoolTimeoutException: Timeout waiting for connection
Stig Even Larsen
2013-10-15 12:03:32 UTC
Permalink
Hi,

I have a problem with webservice (JAX-WS and Axis2) requests being rejected
by HttpClient (MultiThreadedHttpConnectionManager) with the message
"Timeout waiting for connection".
We are using Geronimo 2.2.1 binary distribution (with Axis 1.5.2)

The system have 2 long running webservices for transferring data to a
legacy system supporting webservices. We now need to consume several other
webservices from the same host, but is running into problems because of the
the default max connections per host being 2.

After searching for several days I don't find a solution to my problem, so
I reach out to you to hopefully be enlightened.

My questions are:
1. How do I change the default max connections per host?
2. Is there a way to "isolate" the long running webservices so that the new
one runs with a different ConnectionManager?
3. Or is there other solutions to this problem?


Best regards,
Stig Even Larsen
Ivan
2013-10-17 14:53:05 UTC
Permalink
Hi,

Which classes do you use to connect the long running web services ? axis2
client API or jaxws spec API ?

Thanks.
Post by Stig Even Larsen
Hi,
I have a problem with webservice (JAX-WS and Axis2) requests being
rejected by HttpClient (MultiThreadedHttpConnectionManager) with the
message "Timeout waiting for connection".
We are using Geronimo 2.2.1 binary distribution (with Axis 1.5.2)
The system have 2 long running webservices for transferring data to a
legacy system supporting webservices. We now need to consume several other
webservices from the same host, but is running into problems because of the
the default max connections per host being 2.
After searching for several days I don't find a solution to my problem, so
I reach out to you to hopefully be enlightened.
1. How do I change the default max connections per host?
2. Is there a way to "isolate" the long running webservices so that the
new one runs with a different ConnectionManager?
3. Or is there other solutions to this problem?
Best regards,
Stig Even Larsen
--
Ivan
Stig Even Larsen
2013-10-18 19:28:31 UTC
Permalink
Hi,

You might be able to get more accurate answer by this stack trace I hope:

Caused by: org.apache.commons.httpclient.ConnectionPoolTimeoutException:
Timeout waiting for connection
at
org.apache.commons.httpclient.MultiThreadedHttpConnectionManager.doGetConnection(MultiThreadedHttpConnectionManager.java:497)
at
org.apache.commons.httpclient.MultiThreadedHttpConnectionManager.getConnectionWithTimeout(MultiThreadedHttpConnectionManager.java:416)
at
org.apache.commons.httpclient.HttpMethodDirector.executeMethod(HttpMethodDirector.java:153)
at
org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:397)
at
org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:346)
at
org.apache.axis2.transport.http.AbstractHTTPSender.executeMethod(AbstractHTTPSender.java:560)
at
org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:199)
at org.apache.axis2.transport.http.HTTPSender.send(HTTPSender.java:76)
at
org.apache.axis2.transport.http.CommonsHTTPTransportSender.writeMessageWithCommons(CommonsHTTPTransportSender.java:400)
at
org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:225)
at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:435)
at
org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:402)
at
org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:229)
at
org.apache.axis2.client.OperationClient.execute(OperationClient.java:165)
at
org.apache.axis2.jaxws.core.controller.impl.AxisInvocationController.execute(AxisInvocationController.java:554)


Best regards,
Stig Even Larsen
Post by Ivan
Hi,
Which classes do you use to connect the long running web services ? axis2
client API or jaxws spec API ?
Thanks.
Post by Stig Even Larsen
Hi,
I have a problem with webservice (JAX-WS and Axis2) requests being
rejected by HttpClient (MultiThreadedHttpConnectionManager) with the
message "Timeout waiting for connection".
We are using Geronimo 2.2.1 binary distribution (with Axis 1.5.2)
The system have 2 long running webservices for transferring data to a
legacy system supporting webservices. We now need to consume several other
webservices from the same host, but is running into problems because of the
the default max connections per host being 2.
After searching for several days I don't find a solution to my problem,
so I reach out to you to hopefully be enlightened.
1. How do I change the default max connections per host?
2. Is there a way to "isolate" the long running webservices so that the
new one runs with a different ConnectionManager?
3. Or is there other solutions to this problem?
Best regards,
Stig Even Larsen
--
Ivan
--
Mvh,
Stig Even Larsen
Stig Even Larsen
2013-10-21 10:13:32 UTC
Permalink
Hi Ivan,

I could also add that the webservice is created in Netbeans by referencing
the wsdl file.
Therefore, I'm a little uncertain answering your question, but to my
knowledge it is Axis2 implementation of JAX-WS that is in use.
Hopefully the stack trace in my previous post could answer your question
better.

Looking forward to resolv this puzzle.

Best regards,
Stig
Post by Ivan
Hi,
Which classes do you use to connect the long running web services ? axis2
client API or jaxws spec API ?
Thanks.
Post by Stig Even Larsen
Hi,
I have a problem with webservice (JAX-WS and Axis2) requests being
rejected by HttpClient (MultiThreadedHttpConnectionManager) with the
message "Timeout waiting for connection".
We are using Geronimo 2.2.1 binary distribution (with Axis 1.5.2)
The system have 2 long running webservices for transferring data to a
legacy system supporting webservices. We now need to consume several other
webservices from the same host, but is running into problems because of the
the default max connections per host being 2.
After searching for several days I don't find a solution to my problem,
so I reach out to you to hopefully be enlightened.
1. How do I change the default max connections per host?
2. Is there a way to "isolate" the long running webservices so that the
new one runs with a different ConnectionManager?
3. Or is there other solutions to this problem?
Best regards,
Stig Even Larsen
--
Ivan
--
Mvh,
Stig Even Larsen
Ivan
2013-10-21 13:49:30 UTC
Permalink
Hi,

Sorry for the late response, was just busy with other sutff.

The reason I asked this is that, if you are using Axis2 specifc apis, it
is possible to find the configurations to change the max connection number,
while for jaxws client api, IIRC, there is no configuration for this.

Could you show me your client sample codes ?
Post by Stig Even Larsen
Hi Ivan,
I could also add that the webservice is created in Netbeans by referencing
the wsdl file.
Therefore, I'm a little uncertain answering your question, but to my
knowledge it is Axis2 implementation of JAX-WS that is in use.
Hopefully the stack trace in my previous post could answer your question
better.
Looking forward to resolv this puzzle.
Best regards,
Stig
Post by Ivan
Hi,
Which classes do you use to connect the long running web services ? axis2
client API or jaxws spec API ?
Thanks.
Post by Stig Even Larsen
Hi,
I have a problem with webservice (JAX-WS and Axis2) requests being
rejected by HttpClient (MultiThreadedHttpConnectionManager) with the
message "Timeout waiting for connection".
We are using Geronimo 2.2.1 binary distribution (with Axis 1.5.2)
The system have 2 long running webservices for transferring data to a
legacy system supporting webservices. We now need to consume several other
webservices from the same host, but is running into problems because of the
the default max connections per host being 2.
After searching for several days I don't find a solution to my problem,
so I reach out to you to hopefully be enlightened.
1. How do I change the default max connections per host?
2. Is there a way to "isolate" the long running webservices so that the
new one runs with a different ConnectionManager?
3. Or is there other solutions to this problem?
Best regards,
Stig Even Larsen
--
Ivan
--
Mvh,
Stig Even Larsen
--
Ivan
Stig Even Larsen
2013-10-21 14:32:16 UTC
Permalink
Hi Ivan,

Don't have any code where I am now, bit it seems to be Axis2. Where can I
find the config ?
Post by Ivan
Hi,
Sorry for the late response, was just busy with other sutff.
The reason I asked this is that, if you are using Axis2 specifc apis, it
is possible to find the configurations to change the max connection number,
while for jaxws client api, IIRC, there is no configuration for this.
Could you show me your client sample codes ?
Post by Stig Even Larsen
Hi Ivan,
I could also add that the webservice is created in Netbeans by
referencing the wsdl file.
Therefore, I'm a little uncertain answering your question, but to my
knowledge it is Axis2 implementation of JAX-WS that is in use.
Hopefully the stack trace in my previous post could answer your question
better.
Looking forward to resolv this puzzle.
Best regards,
Stig
Post by Ivan
Hi,
Which classes do you use to connect the long running web services ?
axis2 client API or jaxws spec API ?
Thanks.
Post by Stig Even Larsen
Hi,
I have a problem with webservice (JAX-WS and Axis2) requests being
rejected by HttpClient (MultiThreadedHttpConnectionManager) with the
message "Timeout waiting for connection".
We are using Geronimo 2.2.1 binary distribution (with Axis 1.5.2)
The system have 2 long running webservices for transferring data to a
legacy system supporting webservices. We now need to consume several other
webservices from the same host, but is running into problems because of the
the default max connections per host being 2.
After searching for several days I don't find a solution to my problem,
so I reach out to you to hopefully be enlightened.
1. How do I change the default max connections per host?
2. Is there a way to "isolate" the long running webservices so that the
new one runs with a different ConnectionManager?
3. Or is there other solutions to this problem?
Best regards,
Stig Even Larsen
--
Ivan
--
Mvh,
Stig Even Larsen
--
Ivan
Stig Even Larsen
2013-10-24 08:11:34 UTC
Permalink
Hi Ivan,

It is Axis2's implementation of JAX-WS that is in use. Do you know where I
can find the Axis2 config where I can change the concurrent number of
connections per host?

Best regards,
Stig
Post by Stig Even Larsen
Hi Ivan,
Don't have any code where I am now, bit it seems to be Axis2. Where can I
find the config ?
Post by Ivan
Hi,
Sorry for the late response, was just busy with other sutff.
The reason I asked this is that, if you are using Axis2 specifc apis, it
is possible to find the configurations to change the max connection number,
while for jaxws client api, IIRC, there is no configuration for this.
Could you show me your client sample codes ?
Post by Stig Even Larsen
Hi Ivan,
I could also add that the webservice is created in Netbeans by
referencing the wsdl file.
Therefore, I'm a little uncertain answering your question, but to my
knowledge it is Axis2 implementation of JAX-WS that is in use.
Hopefully the stack trace in my previous post could answer your question
better.
Looking forward to resolv this puzzle.
Best regards,
Stig
Post by Ivan
Hi,
Which classes do you use to connect the long running web services ?
axis2 client API or jaxws spec API ?
Thanks.
Post by Stig Even Larsen
Hi,
I have a problem with webservice (JAX-WS and Axis2) requests being
rejected by HttpClient (MultiThreadedHttpConnectionManager) with the
message "Timeout waiting for connection".
We are using Geronimo 2.2.1 binary distribution (with Axis 1.5.2)
The system have 2 long running webservices for transferring data to a
legacy system supporting webservices. We now need to consume several other
webservices from the same host, but is running into problems because of the
the default max connections per host being 2.
After searching for several days I don't find a solution to my
problem, so I reach out to you to hopefully be enlightened.
1. How do I change the default max connections per host?
2. Is there a way to "isolate" the long running webservices so that
the new one runs with a different ConnectionManager?
3. Or is there other solutions to this problem?
Best regards,
Stig Even Larsen
--
Ivan
--
Mvh,
Stig Even Larsen
--
Ivan
--
Mvh,
Stig Even Larsen
Loading...