cxf-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tcs <tah...@hotmail.com>
Subject Re: java.lang.NoClassDefFoundError: com.sun.org.apache.xerces.internal.dom.ElementNSImpl
Date Fri, 07 Dec 2007 19:58:50 GMT

I added "jaxp-ri-1.4.jar" to the client classpath and now an
'UnsupportedClassVersionError' exception occurs.

Exception in thread "main" java.lang.UnsupportedClassVersionError:
(com/sun/org/apache/xerces/internal/dom/ElementNSImpl) bad major version at
offset=6
	at java.lang.ClassLoader.defineClassImpl(Native Method)
	at java.lang.ClassLoader.defineClass(ClassLoader.java:223)
	at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:148)
	at java.net.URLClassLoader.defineClass(URLClassLoader.java:556)
	at java.net.URLClassLoader.access$400(URLClassLoader.java:119)
	at java.net.URLClassLoader$ClassFinder.run(URLClassLoader.java:961)

These are some of the jars in the client's classpath:
cxf-2.0.3-incubator.jar
saaj-api-1.3.jar
saaj-impl-1.3.jar
jaxb-api-2.0.jar
jaxb-impl-2.0.5.jar
jaxp-ri-1.4.jar
jaxws-api-2.0.jar
stax-api-1.0.1.jar
wstx-asl-3.2.1.jar
xml-resolver-1.2.jar
XmlSchema-1.3.2.jar
......





tcs wrote:
> 
> I've deployed my HelloWorld Webservice on tomcat. 
> 
> I wrote a spring client and am trying to access the web service through
> it.  
> 
>     public static void main(String[] theArgs) { 
>       
>     	ClassPathXmlApplicationContext appContext = new
> ClassPathXmlApplicationContext( "./beans.xml");
>         HelloWorld client = (HelloWorld)appContext.getBean("client");
>         String[] array = client.getArray();
>     	System.out.println("done");
>     }
> 
> When executing the operation, 'client.getArray()', the following exception
> occurs.  How can I resolve this error?
> 
> 
> INFO: Interceptor has thrown exception, unwinding now
> org.apache.cxf.interceptor.Fault: Could not send Message.
> 	at
> org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingInterceptor.handleMessage(MessageSenderInterceptor.java:64)
> 	at
> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:207)
> 	at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:254)
> 	at org.apache.cxf.endpoint.ClientImpl.invoke(ClientImpl.java:205)
> 	at org.apache.cxf.frontend.ClientProxy.invokeSync(ClientProxy.java:73)
> 	at
> org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:135)
> 	at $Proxy14.getArray(Unknown Source)
> 	at demo.test.ClientTest.<init>(ClientTest.java:17)
> 	at demo.test.ClientTest.main(ClientTest.java:22)
> Caused by: java.io.IOException: Not Found
> 	at
> org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponse(HTTPConduit.java:1888)
> 	at
> org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(HTTPConduit.java:1791)
> 	at
> org.apache.cxf.transport.AbstractConduit.close(AbstractConduit.java:66)
> 	at org.apache.cxf.transport.http.HTTPConduit.close(HTTPConduit.java:575)
> 	at
> org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndingInterceptor.handleMessage(MessageSenderInterceptor.java:62)
> 	... 8 more
> Exception in thread "main" java.lang.NoClassDefFoundError:
> com.sun.org.apache.xerces.internal.dom.ElementNSImpl
> 	at java.lang.ClassLoader.defineClassImpl(Native Method)
> 	at java.lang.ClassLoader.defineClass(ClassLoader.java:223)
> 	at
> java.security.SecureClassLoader.defineClass(SecureClassLoader.java:148)
> 	at java.net.URLClassLoader.defineClass(URLClassLoader.java:556)
> 	at java.net.URLClassLoader.access$400(URLClassLoader.java:119)
> 	at java.net.URLClassLoader$ClassFinder.run(URLClassLoader.java:961)
> 	at java.security.AccessController.doPrivileged(AccessController.java:275)
> 	at java.net.URLClassLoader.findClass(URLClassLoader.java:487)
> 	at java.lang.ClassLoader.loadClass(ClassLoader.java:606)
> 	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:327)
> 	at java.lang.ClassLoader.loadClass(ClassLoader.java:563)
> 	at java.lang.ClassLoader.defineClassImpl(Native Method)
> 	at java.lang.ClassLoader.defineClass(ClassLoader.java:223)
> 	at
> java.security.SecureClassLoader.defineClass(SecureClassLoader.java:148)
> 	at java.net.URLClassLoader.defineClass(URLClassLoader.java:556)
> 	at java.net.URLClassLoader.access$400(URLClassLoader.java:119)
> 	at java.net.URLClassLoader$ClassFinder.run(URLClassLoader.java:961)
> 	at java.security.AccessController.doPrivileged(AccessController.java:275)
> 	at java.net.URLClassLoader.findClass(URLClassLoader.java:487)
> 	at java.lang.ClassLoader.loadClass(ClassLoader.java:606)
> 	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:327)
> 	at java.lang.ClassLoader.loadClass(ClassLoader.java:563)
> 	at java.lang.ClassLoader.defineClassImpl(Native Method)
> 	at java.lang.ClassLoader.defineClass(ClassLoader.java:223)
> 	at
> java.security.SecureClassLoader.defineClass(SecureClassLoader.java:148)
> 	at java.net.URLClassLoader.defineClass(URLClassLoader.java:556)
> 	at java.net.URLClassLoader.access$400(URLClassLoader.java:119)
> 	at java.net.URLClassLoader$ClassFinder.run(URLClassLoader.java:961)
> 	at java.security.AccessController.doPrivileged(AccessController.java:275)
> 	at java.net.URLClassLoader.findClass(URLClassLoader.java:487)
> 	at java.lang.ClassLoader.loadClass(ClassLoader.java:606)
> 	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:327)
> 	at java.lang.ClassLoader.loadClass(ClassLoader.java:563)
> 	at
> com.sun.xml.messaging.saaj.soap.ver1_1.SOAPFactory1_1Impl.createFault(SOAPFactory1_1Impl.java:62)
> 	at
> org.apache.cxf.jaxws.JaxWsClientProxy.invoke(JaxWsClientProxy.java:151)
> 	at $Proxy14.getArray(Unknown Source)
> 	at demo.test.ClientTest.<init>(ClientTest.java:17)
> 	at demo.test.ClientTest.main(ClientTest.java:22)
> 

-- 
View this message in context: http://www.nabble.com/java.lang.NoClassDefFoundError%3A-com.sun.org.apache.xerces.internal.dom.ElementNSImpl-tf4964065.html#a14219620
Sent from the cxf-user mailing list archive at Nabble.com.


Mime
View raw message