Win a copy of Practical SVG this week in the HTML/CSS/JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

IllegalThreadStateException: Interrupted while waiting in MultiThreadedHttpConnectionManager

 
Siddharth Pareek
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Hi,
In my SOAP web service I am getting this exception java.lang.IllegalThreadStateException: Interrupted while waiting in MultiThreadedHttpConnectionManager, whenever there are huge request I am making for some service which is being deployed on a 3rd party server.

I am not able to identify how should I handle this kind of error since it goes out of the scope of my code when I call the locator class. Below is the code snippet of the configuration which I am doing before calling this service.

SimpleProvider clientConfig = new SimpleProvider(new BasicClientConfig());
SimpleChain reqHandler = new SimpleTargetedChain(new CommonsHTTPSender());
SimpleChain respHandler = new SimpleTargetedChain(new CommonsHTTPSender());
Handler pivot = (Handler) new CommonsHTTPSender();
Handler transport = new SimpleTargetedChain(reqHandler, pivot, respHandler);
clientConfig.deployTransport(HTTPTransport.DEFAULT_TRANSPORT_NAME, transport);


I am using Axis 1.4 since I am using Java version 1.4 and I cannot upgrade the java version to 1.5 or higher hence cannot implement Axis 2 too.

But I read somewhere that in Axis 2 you can making following kind of changes to your code, so if you can suggest some alternative to it that will also be a great help:

configurationContext = Packages.org.apache.axis2.context.ConfigurationContextFactory.createDefaultConfigurationContext();
configurationContext.setProperty(org.apache.axis.transport.http.HTTPConstants.CACHED_HTTP_CLIENT, Packages.com.intervoice.scxml.http.actions.HTTPResource.client);
configurationContext.setProperty(Packages.org.apache.axis2.transport.http.HTTPConstants.REUSE_HTTP_CLIENT, true);

 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!