Been really clueless on this issue for past 2 nights, the Apache CXF deployment on Websphere 7 just doesn't seem to work.
Environment : cxf 2.4.1, websphere 7.0.0.17, Jars in web-inf/lib do not have woodstox / jaxb-impl. Class Loading policy - parent last, DisableIBMJaxWsEngine = True
Our CXF using APP contains both CXF clients and services. The RS services seem to receive the requests and process them, but the Client components continuously fail with this error :
Caused by: java.lang.VerifyError: org/w3c/dom/Node.setUserData(Ljava/lang/String;Ljava/lang/Object;Lorg/w3c/dom/UserDataHandler;)Ljava/lang/Object;
org.apache.cxf.staxutils.StaxUtils.addLocation(StaxUtils.java:1083)
org.apache.cxf.staxutils.StaxUtils.readDocElements(StaxUtils.java:971)
org.apache.cxf.staxutils.StaxUtils.readDocElements(StaxUtils.java:947)
org.apache.cxf.staxutils.StaxUtils.read(StaxUtils.java:874)
org.apache.cxf.wsdl11.WSDLManagerImpl.loadDefinition(WSDLManagerImpl.java:226)
org.apache.cxf.wsdl11.WSDLManagerImpl.getDefinition(WSDLManagerImpl.java:186)
org.apache.cxf.wsdl11.WSDLServiceFactory.<init>(WSDLServiceFactory.java:92)
org.apache.cxf.jax开发者_Go百科ws.ServiceImpl.initializePorts(ServiceImpl.java:203)
org.apache.cxf.jaxws.ServiceImpl.<init>(ServiceImpl.java:147)
org.apache.cxf.jaxws.spi.ProviderImpl.createServiceDelegate(ProviderImpl.java:90)
javax.xml.ws.Service.<init>(Service.java:67)
Vineet this is clearly an error due to mismatch in Xerces parser. use the below trick to find the exact jar used at the time of executing your service. org.apache.xerces.parsers.DOMParser.class.getProtectionDomain().getCodeSource().getLocation()
Then verify the version and replace with latest.
If its not solved then repeat the exercise with each of the conflicting jars saaj-api.jar saaj-impl.jar xalan.jar xercesImpl.jar xml-apis.jar jaxb-api.jar jaxb-impl.jar
I had similar problem with CXF + XmlBeans + WebSphere, and i solved it by removing the org/w3c/dom package from XmlBeans dependency using truezip-maven-plugin.
精彩评论