我有一个部署在 WebSphere 9.0.5.2 上的应用程序,我想在其中使用 CXF 进行 Web 服务调用,我得到了这个 This ServiceConfigurationError
WrapperedException { java.util.ServiceConfigurationError: javax.xml.ws.spi.Provider: Provider org.apache.cxf.jaxws.spi.ProviderImpl could not be instantiated
在堆栈跟踪的下方,我看到这是由 LinkageError 引起的
Caused by: java.lang.LinkageError: loading constraint violation when overriding method
"javax/xml/ws/spi/ServiceDelegate.createDispatch(Ljavax/xml/namespace/QName;Ljavax/xml/bind/JAXBContext;Ljavax/xml/ws/Service$Mode;)Ljavax/xml/ws/Dispatch;" during creation of class
"org/apache/cxf/jaxws/ServiceImpl": loader
"com/ibm/ws/classloader/CompoundClassLoader@832133d2" of class
"org/apache/cxf/jaxws/ServiceImpl" and loader
"com/ibm/oti/vm/BootstrapClassLoader@2eec706a" of class
"javax/xml/ws/spi/ServiceDelegate" have different types for the method signature
我知道这可能是由对QName
or具有不同定义的多个库引起的JAXBContext
,但我想我已经排除了这些。
我也知道 WebSphere 有它自己的 JAX-WS 和它自己的 ServiceDelegate.createDispatch 方法签名,我已经尝试DisableIBMJAXWSEngine
按照此处的说明在 WebSphere 中设置为 true
我仍然无法摆脱错误,并且对于接下来要尝试什么感到不知所措。任何建议表示赞赏!