Question

I have created a Web Service in Net Beans 6.9 and deploy it locally. And I am using it via a java SE application by adding Web Service client in this application. How to obtain the link of the Web Serice so that it can be used from anywhere ?

2) From where to obtain WSDL file of Web Service ?

3) How to host a Web Service on the internet ?

Thank a ton in advance..!!!

Was it helpful?

Solution

You could create a new project of type web application in Netbeans. In the web application, you will then create a web service (NOT a web service client).

For publishing and testing the web application, you will have to deploy it to a web server (e.g. GlassFish).

After publishing the web application, the WSDL file will be typically located at: http://localhost:<port>/<your web app>/<your service>?wsdl

For GlassFish, the default port is 8080.

If your current Netbeans installation doesn't support web projects or you don't have GlassFish installed, I suggest you download and install the latest version of Netbeans with Java EE support (bundled Apache Tomcat and GlassFish server in the same setup).

http://netbeans.org/downloads/index.html

OTHER TIPS

Hosting SOAP web services on the internet at large has not been terribly successful. For example Google had SOAP based web services initially, and they switched to REST based services in the end. You may want to reconsider and deploy a REST based interface. If the bulk of your code is not embedded in the web service, then you should not have that difficult of a time switching the interface.

To deploy a SOAP or a REST web service, you would need to deploy a 'full' Java EE container (e.g. Glassfissh or JBoss) on a machine with access to the internet. You might virtual hosting e.g. Westhost, Amazon, or there are turnkey solutions like Heroku (note: I'm not endorsing any of the companies listed here; they're just examples). If you just want to deploy a REST based service, any web container will do e.g. Tomcat or Jetty. In addition to services mentioned above you could probably host a rest web service on any service that will let you upload a war file.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top