我正在開發基於Struts 2.0.11,Spring和Hibernate的Web應用程序。我應該在基於Struts 2.0.11的Web應用程序中使用哪種調度程序?
我不知道我應該在web.xml文件中聲明哪個調度程序。
我應該使用FilterDispatche
r?過濾分派器+ ActionContextCleanUp?或者StrutsPrepareAndExecuteFilter?或者StrutsPrepareAndExecuteFilter + ActionContextCleanUp?
如今,web.xml文件包含以下代碼:
<filter>
<filter-name>struts2</filter-name>
<filter-class>org.apache.struts2.dispatcher.FilterDispatcher</filter-class>
</filter>
<filter-mapping>
<filter-name>struts2</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>
<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>
非常感謝
您是否擺脫了困惑? – developer 2011-05-27 05:07:40
是啊!無論如何,應用程序以相同的方式運行。謝謝! – StrutsLearner 2011-05-27 08:02:22