• Post Reply Bookmark Topic Watch Topic
  • New Topic

help on webservices with java/axis

 
Ravi Veerla
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am writing a web service using java/axis. I am using a third party java api, and build webservices using the class files developed by them. initially i had trouble using their packages, as i dint know where to place the third party class files. then i could figure out that the classes folder in webinf folder in axis is meant for the classes that are used by the jws classes. and it solved my problem with using those packages.

but i have another problems. the third party api's use some config files(typically xml) and when i run them as normal applications i include the path of these config files in the class path. im confused as to where these config files should be placed for axis to find them when it runs the class files.

can anyone suggest me a solution or point me to resources where i can find information.

thanks in advance.
Ravi
 
Ulf Dittmer
Rancher
Posts: 42970
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If it works in a desktop app by including the config files in the classpath, why wouldn't it work the same way in a web app? What happens if you put those files in WEB-INF/classes?
 
Ravi Veerla
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ulf,

It throwns an exception saying it cannot load the url for one of the config files. it is the first config file that the api uses. i tried by copying those config files in to the java home directory too. it dint seem to work. i think il get with those third party people to see what im missing.

if anyone can find a solution to this problem, please let me know.

thanks
Ravi
 
Manuel Moons
Ranch Hand
Posts: 229
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
What does the exeption say? Where is it trying to locate the property files?
 
Ravi Veerla
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
java.lang.Exception: ERROR: failed to load URL for file = webmail.xml
this is what it says .. the rest is the stack trace of the classes of the third party api.. i dont have access to the source code so, i dont where it is looking for
 
Ravi Veerla
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hey guys,
I figured out a solution. i added the path of the config files to the classpath int the tomcat setclasspath.bat/setclasspath.sh. so tomcat is able to find these files now. the default was to the java home directory.

thanks,
Ravi
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!