【问题标题】:Websphere 8.x not able to identify axis 1.4 jar in WEB-INF/libWebsphere 8.x 无法识别 WEB-INF/lib 中的轴 1.4 jar
【发布时间】:2014-06-19 21:20:10
【问题描述】:

我在 websphere 8.5 服务器中构建并部署了一个 war 文件。所有与轴 1.4 相关的 jar 都放在 WEB-INF/lib 文件夹中。但是,当我运行应用程序并尝试访问调用 web 服务的代码时,我得到以下错误。相同的战争文件在 TOMCAT 7 服务器中工作正常。我确实看到axis.jar 存在并包含axisfault.class。请帮忙。

Caused by: java.lang.NoClassDefFoundError: org.apache.axis.AxisFault
    at java.lang.J9VMInternals.verifyImpl(Native Method)
    at java.lang.J9VMInternals.verify(J9VMInternals.java:93)
    at java.lang.J9VMInternals.initialize(J9VMInternals.java:170)
    at java.lang.Class.forNameImpl(Native Method)
    at java.lang.Class.forName(Class.java:179)
    at org.uddi4j.transport.TransportFactory.getTransport(TransportFactory.java:61)
    at org.uddi4j.client.UDDIProxy.send(UDDIProxy.java:1940)
    at org.uddi4j.client.UDDIProxy.find_service(UDDIProxy.java:888)
    at bofasecurity.UDDIHelper.getEndPoint(UDDIHelper.java:70)
    at bofasecurity.xxxxSecurityWrapper.buildBofASecurityWrapper(BofASecurityWrapper.java:273)
    at bofasecurity.xxxxSecurityWrapper.<init>(BofASecurityWrapper.java:212)
    at bofasecurity.xxxxSecurityWrapper$Builder.build(BofASecurityWrapper.java:179)
    at com.ml.grci.service.impl.SearchACCLServiceImpl.buildSecWrapper(SearchACCLServiceImpl.java:721)
    at com.ml.grci.service.impl.SearchACCLServiceImpl.searchACCL(SearchACCLServiceImpl.java:160)
    at com.ml.grci.webapp.action.ACCLSearchAction.execute(ACCLSearchAction.java:233)
    ... 83 more
Caused by: java.lang.ClassNotFoundException: org.apache.axis.AxisFault
    at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:506)
    at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:422)
    at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:410)
    at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:650)

【问题讨论】:

    标签: java web-services websphere axis soap-client


    【解决方案1】:

    这可能是由于类加载器问题。 WebSphere 8.5 加载axis.jar(参见/deploytool/itp/plugins/org.apache.axis_1.4.0.v201005080400/lib)。建议删除冲突的 jar 或更改类加载器策略(PARENT LAST)。见how to set java class loader PARENT_LAST

    也不确定这是否会有所帮助,但是如果您尝试使用第三方框架进行 Web 服务,那么有一篇非常好的文章介绍了如何做到这一点:http://www.ibm.com/developerworks/websphere/library/techarticles/1001_thaker/1001_thaker.html

    【讨论】:

    • 谢谢!是的,这是 jar 文件冲突,最后与父级一起使用。但最后我最终将其编码为使用 WAS 8.5 上可用的 AXIS jar。
    猜你喜欢
    • 2015-09-17
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2010-11-29
    • 2012-01-11
    • 2018-05-26
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多