• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

how to set Timeout for download of wsdl dynamically

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I want to put connection timeout when wsdl is provided for javax.xml.ws.Service((java.net.URL wsdlDocumentLocation, QName serviceName) to get the ServiceDelegate object.
The requirement is because we are providing the wsdlDocumentLocation dynamically and if the url is wrong or server is not available then the application hangs.

I cant use the option of storing the wsdl locally and use it.


Any help on this topic is welcome.

Thanks in advance.
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The URLConnection class in the java.net package provides the setConnectTimeout( int millisec ) method - why not use that?

Bill
 
rakesh kanchalwar
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If you are suggesting a way to download the wsdl with URLConnection and then use it for javax.xml.ws.Service(..... , ....); then can we validate the wsdl fetched with this way and how to validate.
What if the url is wrong pointing to location which is not wsdl location OR it is pointing to a wrong wsdl?

Thanks for your suggestion.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic