`
myyxh999
  • 浏览: 17536 次
  • 性别: Icon_minigender_2
  • 来自: 杭州
文章分类
社区版块
存档分类
最新评论

Exception starting filter struts-cleanup

阅读更多

错误:

严重: Exception starting filter struts-cleanup
java.lang.ClassNotFoundException: org.apache.Struts2.dispatcher.ActionContextCleanUp

 

我的web.xml:

<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:javaee="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd" id="WebApp_ID" version="2.4">
  <filter>
   <filter-name>struts-cleanup</filter-name>
   <filter-class>org.apache.Struts2.dispatcher.ActionContextCleanUp</filter-class>
  </filter>
  <filter>
    <filter-name>struts2</filter-name>
    <filter-class>org.apache.struts2.dispatcher.FilterDispatcher</filter-class>
  </filter>
   <filter-mapping>
   <filter-name>struts-cleanup</filter-name>
   <url-pattern>/*</url-pattern>
  </filter-mapping> 
  <filter-mapping>
    <filter-name>struts2</filter-name>
    <url-pattern>/*</url-pattern>
  </filter-mapping>
  <welcome-file-list>
    <welcome-file>login.jsp</welcome-file>
  </welcome-file-list>
</web-app>

 

后来移除掉Struts2-cleanup之后运行成功了。

 

不明白为什么添加struts-cleanup之后会出现这个错误,原来以为是版本的原因,换了一下,还是一样的错误,真的是弄不明白。

分享到:
评论
1 楼 yangguangpiaosa 2011-08-05  
<filter>
   <filter-name>struts-cleanup</filter-name>
   <filter-class>org.apache.Struts2.dispatcher.ActionContextCleanUp</filter-class>
</filter>
中的filter-class中struts2要小写,而不是Struts2

相关推荐

Global site tag (gtag.js) - Google Analytics