• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Accessing web service

 
Anbarasu Selvaraj
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Guy's please tell me how to invoke(or access) webservices
 
vikram Kesav
Ranch Hand
Posts: 69
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You can access any web service using WSDL file.

approach is like-

1) First identify WSDL file.
2) Create stubs of WS using WSDLToJava command.
3) Identify authentication if required, and call same in your call from client.
 
Anbarasu Selvaraj
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank You Vikram.

But, the Stub Creation is giving error. (For WSDL File i am Giving URL)
 
vikram Kesav
Ranch Hand
Posts: 69
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Can you paste error message and let me know the WSDL link if it is not password protected.
 
Anbarasu Selvaraj
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The Error Message is,
Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/axis/wsdl/WSDL2Java

all jar files are included in classpath
 
vikram Kesav
Ranch Hand
Posts: 69
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Just make sure....Do you have any of the below jar file in your classpath.

What IDE you are using? try to set axis jars classpath on command prompt and run WSDL2Java command from there.


Information on class org.apache.axis.wsdl.WSDL2Java:

Containing JAR files:
axis.jar
axis-1.0.jar
axis-1.1.jar
axis-1.2.1.jar
axis-1.2.jar
axis-1.3.jar
axis-1.4.jar
axis-1.4.jar
axis-1.1-beta.jar
axis-1.2-RC1.jar
axis-1.2-RC2.jar
axis-1.2-RC3.jar
axis-1.2-alpha-1.jar
axis-1.2-beta-2.jar
axis-1.2-beta-3.jar

 
Anbarasu Selvaraj
Greenhorn
Posts: 21
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank You Vikram. Eclipse it's working.( still, command line it's not working.)
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic