Hello all, I am facing a problem deploying SOAP over JMS and hope that somebody can provide some tip. I am using openJMS and Axis for asynchronous calling of web services., I use a JMS sender to send the message to the queue. I have a JMS listener that retrieves the SOAP msg from the queue and invokes the web service. but at the server, when this jms listener creates an axis instance and tries to invoke the service, i get this error as posted below. I don�t know why I get that message. I have checked the deployment of the web service and I am able to call it over HTTP using a regular client but this call over JMS fails. I have checked all the problems why this error occurs but I feel that the ClassNotFoundExcetion is unsual since I can call it over a regular client. Any help is appreciated . Thanks Saurabh ---Invoking AxisServer.invoke()--- - Exception: java.lang.ClassNotFoundException: workflow.SparePartPrice at java.net.URLClassLoader$1.run(Unknown Source) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClass(Unknown Source) at java.lang.ClassLoader.loadClassInternal(Unknown Source) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Unknown Source) The AXIS engine could not find a target service to invoke! targetService is null at org.apache.axis.server.AxisServer.invoke(AxisServer.java:308) at org.apache.axis.transport.jms.SimpleJMSWorker.run(SimpleJMSWorker.java:127)
This sounds like you have the axis.jar in a different web application than the target service's client stubs. Could you describe where have you placed the .jar files for OpenJMS, Axis, and "workflow.SparePartPrice"?
Hello I did not get what you were referring to. I have the OpenJMS jar files in its own folder C:/OpenJMS/lib. I have added the required jars to my class path. I have the axis jars in the folder in C:/tomcat/webapps/axis/web-inf/lib Again i have added all these jars in my classpath. Workflow.SparePartPrice is the service i am trying to call. I have put the .class file SparePartPrice.class in the folder C:/tomcat/webapps/axis/web-inf/classes/workflow Do you see anything i should have done diffrently? thanks Saurabh
Joined: Jan 23, 2002
What I was after is that if the Axis classes are loaded by the "system classloader", they won't see classes loaded by a lower-level "web application classloader". Thus, if your Axis library would've been loaded by the system classloader (i.e. loaded from the classpath), it could result in the kind of an error message you're seeing.
Joined: Feb 29, 2004
That is a good point. When i was getting this error what i tried at one point to give the entire path of the workflow.SparePartService.clss in the classpath. Thus it would have been loaded with the Axis jars but still that did not solve the problem. Somehow i feel the problem is related to how the AXIS engine loads the webservice, but am not able to pinpoit it exactly. Any other suggestions? Thanks for your help.This discussion is getting me started to think in some new ways to get over this. Saurabh