工作开发异常记录java.lang.NoClassDefFoundError: org/apache/jsp/Index_jsp
一晃,一个月又完了。中午利用午休的时间,记录个我最近开发遇到的异常。
下面是异常提示信息:
严重: Servlet.service() for servlet jsp threw exception java.lang.NoClassDefFoundError: org/apache/jsp/Index_jsp (wrong name: org/apache/jsp/index_jsp) at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClassCond(ClassLoader.java:632) at java.lang.ClassLoader.defineClass(ClassLoader.java:616) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141) at java.net.URLClassLoader.defineClass(URLClassLoader.java:283) at java.net.URLClassLoader.access$000(URLClassLoader.java:58) at java.net.URLClassLoader$1.run(URLClassLoader.java:197) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:190) at org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:134) at org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:66) at org.apache.jasper.JspCompilationContext.load(JspCompilationContext.java:618) at org.apache.jasper.servlet.JspServletWrapper.getServlet(JspServletWrapper.java:144) at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:329) at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:342) at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:267) at javax.servlet.http.HttpServlet.service(HttpServlet.java:717) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:845) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583) at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447) at java.lang.Thread.run(Thread.java:662)
产生这个异常的时候,我是正常操作,停止Tomcat服务,然后开始编辑代码。当我的代码编辑完成后,在Eclipse上也没有发现编写上的错误。然后开始启动Tomcat,就开始报这个异常,启动失败。