概述
环境:Tomcat6.0 Eclipse3.4 jdk1.5
一周前我用的时候还可以运行,期间我在机器上装了一个MyEclipse6.0在MyEclipse中运行struts2的application就出现此错误,之后我把MyEclipse卸载,又重装了Tomcat,启动Eclipse运行软件还是有这个错误
type Exception report
message
description The server encountered an internal error () that prevented it from fulfilling this request.
exception
javax.servlet.ServletException: javax.servlet.ServletException: java.lang.NoClassDefFoundError: javax/el/ELResolver
com.neusoft.unieap.service.security.ui.webapp.UniEAPSecurityEnforcementFilter.doFilter(UniEAPSecurityEnforcementFilter.java:174)
......
org.ecside.filter.ECSideFilter.doFilter(ECSideFilter.java:161)
com.neusoft.unieap.comp.transcoding.TranscodingFilter.doFilter(TranscodingFilter.java:35)
root cause
javax.servlet.ServletException: java.lang.NoClassDefFoundError: javax/el/ELResolver
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:274)
javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
.............
net.sf.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:303)
com.neusoft.unieap.service.security.context.HttpSessionContextIntegrationFilter.doFilter(HttpSessionContextIntegrationFilter.java:263)
net.sf.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:303)
net.sf.acegisecurity.util.FilterChainProxy.doFilter(FilterChainProxy.java:173)
net.sf.acegisecurity.util.FilterToBeanProxy.doFilter(FilterToBeanProxy.java:125)
org.ecside.filter.ECSideFilter.doFilter(ECSideFilter.java:161)
com.neusoft.unieap.comp.transcoding.TranscodingFilter.doFilter(TranscodingFilter.java:35)
note The full stack trace of the root cause is available in the Apache Tomcat/6.0.1 logs.
NoClassDefFoundError: javax/el/ELResolver产生此错误的原因有很多种(仅列举我遇到的两种)。
产生此错误
1.首先检查一下Tomcat/lib下是否已经有el-api.jar el-ri.jar两个jar文件,没有则拷贝到此目录下。重启Eclipse测试
2. 如果机器上已经有Eclipse,又安装MyEclipse,MyEclipse会自动查找jre,他首先检测到的是C:/Program Files/Java(jdk安装目录)中的jre,而不是C:/Program Files/Java/jdk1.5.0_06中的jre,原先的Eclipse的jre也随之改动。
解决方法(Eclipse为例,MyEclipse类似)window->preferences->Java->Installed JRES->Edit->更改jre home为C:/Program Files/Java/jdk1.5.0_06
简单的问题困扰了我一天,在此共享希望对需要的人有所帮助。
最后
以上就是秀丽雨为你收集整理的NoClassDefFoundError: javax/el/ELResolver问题解决的全部内容,希望文章能够帮你解决NoClassDefFoundError: javax/el/ELResolver问题解决所遇到的程序开发问题。
如果觉得靠谱客网站的内容还不错,欢迎将靠谱客网站推荐给程序员好友。
发表评论 取消回复