java.lang.NoSuchMethodError: javax.servlet.jsp.JspFactory.getJspApplicationConte错误

java.lang.NoSuchMethodError: javax.servlet.jsp.JspFactory.getJspApplicationConte

(2010-11-09 09:19:06)
转载
标签:

杂谈

分类: java

HTTP Status 500 -


type Exception report

message

description The server encountered an internal error () that prevented it from fulfilling this request.

exception

javax.servlet.ServletException: java.lang.NoSuchMethodError: javax.servlet.jsp.JspFactory.getJspApplicationContext(Ljavax/servlet/ServletContext;)Ljavax/servlet/jsp/JspApplicationContext; org.apache.jasper.servlet.JspServlet.service(JspServlet.java:275) javax.servlet.http.HttpServlet.service(HttpServlet.java:717)

 

root cause

java.lang.NoSuchMethodError: javax.servlet.jsp.JspFactory.getJspApplicationContext(Ljavax/servlet/ServletContext;)Ljavax/servlet/jsp/JspApplicationContext; org.apache.jsp.Login_jsp._jspInit(Login_jsp.java:22) org.apache.jasper.runtime.HttpJspBase.init(HttpJspBase.java:52) org.apache.jasper.servlet.JspServletWrapper.getServlet(JspServletWrapper.java:159) org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:329) org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:342) org.apache.jasper.servlet.JspServlet.service(JspServlet.java:267) javax.servlet.http.HttpServlet.service(HttpServlet.java:717)

 

note The full stack trace of the root cause is available in the Apache Tomcat/6.0.20 logs.

 

运行的时候突然出现这个项目,看着错误很长,其实是 tomcat下webapps文件夹下你所运行的工程的web-inf的lib多了两个跟tomcat服务器本身冲突的jar包,把 javax.servlet.jsp.jar和javax.servlet.jar包都删除了就可以正确运行了!
查看了一下,web-inf的lib里的确多了这两个包,删除掉后重新编译却又生成了。。之后,直接删除掉项目,再重新导入、编译,就没发现这个问题了。

你可能感兴趣的:(Java,EE,SSH)