Neeraj Agrawal
Neeraj Agrawal

Reputation: 31

Error while deploying CXF top down web service to Weblogic 12.2.1

It is a simple top down CXF web service created using cxf-codegen-plugin but the following error occurs on deployment of war/ear files to Weblogic 12.2.1 server:

Servlet: "cxf" failed to preload on startup in Web application: "SampleInfo.war".
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'cxf' defined in class path resource [META-INF/cxf/cxf.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [org.apache.cxf.bus.spring.SpringBus]: **Constructor threw exception; nested exception is org.apache.cxf.bus.extension.ExtensionException: Could not load extension class org.apache.cxf.ws.policy.AssertionBuilderRegistryImpl.**
        at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateBean(AbstractAutowireCapableBeanFactory.java:997)

Caused By: org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [org.apache.cxf.bus.spring.SpringBus]: Constructor threw exception; nested exception is org.apache.cxf.bus.extension.ExtensionException: **Could not load extension class org.apache.cxf.ws.policy.AssertionBuilderRegistryImpl.**

**Caused By: org.apache.cxf.bus.extension.ExtensionException: Could not load extension class org.apache.cxf.ws.policy.AssertionBuilderRegistryImpl.**

Caused By: java.lang.IncompatibleClassChangeError: Implementing class
at java.lang.ClassLoader.defineClass1(Native Method)
at java.lang.ClassLoader.defineClass(ClassLoader.java:760)
at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142)
at weblogic.utils.classloaders.GenericClassLoader.defineClassInternal(GenericClassLoader.java:1065)
at weblogic.utils.classloaders.GenericClassLoader.defineClass(GenericClassLoader.java:998)
Truncated. see log file for complete stacktrace
**The dependencies under pom.xml are as under:**

cxf-rt-frontend-jaxws Version 3.1.4
cxf-rt-transports-http Version 3.1.4
cxf-xjc-runtime Version 3.0.5
spring-web Version 4.1.4.RELEASE

Upvotes: 0

Views: 1592

Answers (1)

Neeraj Agrawal
Neeraj Agrawal

Reputation: 31

The neethi.jar and cxf-rt-ws-policy.jar had some conflicts which got resolved while I removed cxf jar from the war file.

Upvotes: 3

Related Questions