Struts2中的ActionContextCleanUp拦截器

<filter>
<filter-name>struts-cleanup</filter-name>
<filter-class>
org.apache.struts2.dispatcher.ActionContextCleanUp
</filter-class>
</filter>
<filter-mapping>
<filter-name>struts-cleanup</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>

该filter清除缓存。在做上传文件时,要在web.xml中增加ActionContextCleanUp这个filter,否则会发生第一次上传取不到文件的情况。




原帖地址:http://blog.sina.com.cn/s/blog_5bd6b45101012i74.html

猜你喜欢

转载自wangdingxin.iteye.com/blog/2312940
今日推荐