[jboss-user] [JBossWS] - lower timeout in accessing a web service

sigitm do-not-reply at jboss.com
Thu Jan 25 16:29:20 EST 2007


Hi,
I'm using this code to connect to a web service:

URL url =  new URL("http://www.mysite.org/WebService?wsdl");
  | 
  | QName qname = new QName("http://www.mysite.org/","WebService");
  |     		            
  | ServiceFactoryImpl factory = new ServiceFactoryImpl();
  | Service service = factory.createService(url, qname);
  | 
  | WebServiceEndpoint endpoint = (WebServiceEndpoint) service.getPort(WebServiceEndpoint.class);


But if the web service is down, this client blocks for about 5 minutes waiting for the web service... till it gives the following exception:

 org.jboss.ws.metadata.wsdl.WSDLException: java.net.ConnectException: Connection timed out: connect

Is there a way to decrease the connection timeout?

Thanks.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4006544#4006544

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4006544



More information about the jboss-user mailing list