• 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
  • Ron McLeod
  • Paul Clapham
  • Devaka Cooray
  • Tim Cooke
Sheriffs:
  • Rob Spoor
  • Liutauras Vilda
  • paul wheaton
Saloon Keepers:
  • Tim Holloway
  • Tim Moores
  • Mikalai Zaikin
  • Carey Brown
  • Piet Souris
Bartenders:
  • Stephan van Hulst

How to call web services from java class

 
Greenhorn
Posts: 22
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have created one webservice Hello.wsdl using eclipse.
It simply accepts String name and Prints Hello <name>
I had tested that using SOAP 3.0 UI. Application.
Now I created Client for Hello.wsdl.

It created in java.src in com.tutorial package.
Now I created one HelloTest class to test that web service.

the webservice code of HelloTest is as follows
/*

But I am getting following Exception...

Exception Occured ...(404)Not Found

I have following queries...

1)What's wrong with this code...
or how can i call web service from java or jsp code..

and 2)when i created the webservice the "wsdlsoap:address location" is of my local machine
if i want to run it on different machine then can I replace the loaclhost address with
new one i.e Client machine IP.

Please Reply.
 
Ranch Hand
Posts: 2198
1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi!
Have you seen these excellent tutorials?
http://www.netbeans.org/kb/docs/websvc/jax-ws.html
http://www.netbeans.org/kb/docs/websvc/client.html
Best wishes!
 
He baked a muffin that stole my car! And this tiny ad:
Smokeless wood heat with a rocket mass heater
https://woodheat.net
reply
    Bookmark Topic Watch Topic
  • New Topic