简体   繁体   English

升级到 WAS 7 后的 javax.servlet.UnavailableException

[英]javax.servlet.UnavailableException after an upgrade to WAS 7

I have migrated my application from WAS 6 to WAS 7. The code is not showing any compilation error or missing anything, but when I am trying to run the application, I get following exception.我已将我的应用程序从 WAS 6 迁移到 WAS 7。代码没有显示任何编译错误或丢失任何内容,但是当我尝试运行该应用程序时,出现以下异常。

 [9/19/12 9:45:37:609 EDT] 00000009 extension     W com.ibm.wsspi.webcontainer.extension.WebExtensionProcessor createServletWrapper Servlet action is currently unavailable: SRVE0203E: Servlet [action]: com.ibm.services.tools.citrus.ctl.ActionServlet was found, but is missing another required class.
    SRVE0206E: This error typically implies that the servlet was originally compiled with classes which cannot be located by the server.

So I checked the ffdc exception trace and I found out following exception.所以我检查了 ffdc 异常跟踪,我发现了以下异常。 I have include all the jar which were referred by the old configuration.我已经包含了旧配置引用的所有 jar。

    [9/19/12 9:26:53:328 EDT]     FFDC Exception:javax.servlet.UnavailableException SourceId:com.ibm.ws.webcontainer.webapp.WebApp.handleError ProbeId:912 Reporter:com.ibm.ws.webcontainer.webapp.WebAppImpl@475c475c
javax.servlet.UnavailableException: SRVE0203E: Servlet [action]: com.ibm.services.tools.citrus.ctl.ActionServlet was found, but is missing another required class.
SRVE0206E: This error typically implies that the servlet was originally compiled with classes which cannot be located by the server.
SRVE0187E: Check your class path to ensure that all classes required by the servlet are present.SRVE0210I: This problem can be debugged by recompiling the servlet using only the classes in the application's runtime class path
    at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:534)
    at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:502)
    at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.handleRequest(ServletWrapperImpl.java:179)
    at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java:354)
    at com.ibm.ws.webcontainer.webapp.WebApp.sendError(WebApp.java:3369)
    at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3968)
    at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:276)
    at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:931)
    at com.ibm.ws.webcontainer.WSWebContainer.handleRequest(WSWebContainer.java:1583)
    at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:186)
    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:452)
    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewRequest(HttpInboundLink.java:511)
    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.processRequest(HttpInboundLink.java:305)
    at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:83)
    at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:165)
    at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217)
    at com.ibm.io.async.AsyncChannelFuture.fireCompletionActions(AsyncChannelFuture.java:161)
    at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:138)
    at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:204)
    at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:775)
    at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:905)
    at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1604)

And I want to understand what is the mean by this problem can be debugged by recompiling the servlet using only the classes in the application's runtime class path.我想了解这个问题是什么意思,可以通过仅使用应用程序运行时类路径中的类重新编译 servlet 来调试。

The error indicates that your servlet is importing or is otherwise dependent on classes which are no longer available after the upgrade.该错误表明您的 servlet 正在导入或依赖升级后不再可用的类。 Since the exception does not name the class which is missing, WAS suggests that you compile your app against the WAS 7 libraries.由于异常未命名缺少的类,WAS 建议您针对 WAS 7 库编译您的应用程序。 If you do this, the compiler will tell you which dependent class is missing.如果你这样做,编译器会告诉你缺少哪个依赖类。 You are probably compiling against WAS 6, or some other libraries, which is why the error is delayed until runtime.您可能正在针对 WAS 6 或其他一些库进行编译,这就是错误延迟到运行时的原因。

Following may be reason for same issue.以下可能是同一问题的原因。

  1. Used libraries/jar is not compatible for ur java version on which application is build.使用的库/jar 与构建应用程序的 Java 版本不兼容。
  2. In my case, i had use two utility.jar(for others may be any other jars) one is build with compatible and one is build with higher version.就我而言,我使用了两个utility.jar(对于其他人可能是任何其他jar),一个是兼容的构建,一个是更高版本的构建。 Solved: When removed higher version jar.解决:当删除更高版本的 jar 时。

Followed below steps which solved the issue:按照以下步骤解决了问题:

1.Pointed JRE and server versions to java 8. ie, The version under Window -> Preferences -> Java -> Installed JREs version and runtime environment of WAS server should be same. 1.将JRE和服务器版本指向java 8,即Window -> Preferences -> Java -> Installed JREs下的版本和WAS服务器的运行环境应该是一样的。 2.Then rebuilt the ears, redeployed these ears on server, after this I am able to run the application 2.然后重建耳朵,在服务器上重新部署这些耳朵,之后我就可以运行应用程序了

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 javax.servlet.UnavailableException:使用jsp的已部署应用程序的持有人中没有类 - javax.servlet.UnavailableException: No class in holder on deployed application with jsp 谷歌应用引擎 .jsp 加载错误 [javax.servlet.UnavailableException] - google app engine .jsp error loading [javax.servlet.UnavailableException] javax.servlet.UnavailableException:SRVE0201E:Servlet [my_ws]:不是Servlet类 - javax.servlet.UnavailableException: SRVE0201E: Servlet [my_ws]: not a servlet class 为什么我有javax.servlet.UnavailableException:我的Filter的CrawlServlet? - Why do i have javax.servlet.UnavailableException: CrawlServlet for my Filter? javax.servlet.UnavailableException:缺少路径/WEB-INF/struts-config.xml的配置资源 - javax.servlet.UnavailableException: Missing configuration resource for path /WEB-INF/struts-config.xml javax.servlet.UnavailableException:EDU / oswego / cs / dl / util / concurrent / ConcurrentHashMap-在Jetty 9.2.2上运行Struts 1.3.5 - javax.servlet.UnavailableException: EDU/oswego/cs/dl/util/concurrent/ConcurrentHashMap - running Struts 1.3.5 on Jetty 9.2.2 控制器spring bean共享属性和引用bean导致javax.servlet.UnavailableException - Controller spring bean share property and reference bean causes javax.servlet.UnavailableException 更新到Spring 2.5.5会导致javax.servlet.UnavailableException:org.springframework.web.struts.DelegatingTilesRequestProcessor - Updating to Spring 2.5.5 causes a javax.servlet.UnavailableException: org.springframework.web.struts.DelegatingTilesRequestProcessor NoClassDefFoundError:javax / servlet / Filter(Objectify升级) - NoClassDefFoundError: javax/servlet/Filter (Objectify Upgrade) NoClassDefFoundError jakarta/servlet/http/HttpSessionContext 升级到 spring 启动后 3 - NoClassDefFoundError jakarta/servlet/http/HttpSessionContext after upgrade to spring boot 3
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM