STRUTS配置文件部署
<?xml version="1.0" encoding="UTF-8"?><web-app version="2.5" xmlns="http://java.sun.com/xml/ns/javaee"xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"><context-param> <param-name>contextConfigLocation</param-name> <param-value> /WEB-INF/configs/service/applicationContext*.xml </param-value></context-param><listener> <listener-class> org.springframework.web.context.ContextLoaderListener </listener-class></listener><listener> <listener-class> com.ambow.ExamOnlineSystem.common.listeners.ContextPathListener </listener-class></listener><filter> <filter-name>hibernateFilter</filter-name> <filter-class> org.springframework.orm.hibernate3.support.OpenSessionInViewFilter </filter-class> <init-param> <param-name>singleSession</param-name> <param-value>false</param-value> </init-param></filter><filter> <filter-name>struts2</filter-name> <filter-class> org.apache.struts2.dispatcher.FilterDispatcher </filter-class></filter><filter-mapping> <filter-name>hibernateFilter</filter-name> <url-pattern>*.action</url-pattern></filter-mapping><filter-mapping> <filter-name>struts2</filter-name> <url-pattern>/*</url-pattern></filter-mapping><servlet> <servlet-name>TestInitServlet</servlet-name> <servlet-class> com.ambow.ExamOnlineSystem.entity.exammanager.service.TestInitServlet </servlet-class></servlet><servlet> <servlet-name>TestServlet</servlet-name> <servlet-class> com.ambow.ExamOnlineSystem.entity.exammanager.action.TestServlet </servlet-class></servlet><servlet-mapping> <servlet-name>TestServlet</servlet-name> <url-pattern>/testServlet</url-pattern></servlet-mapping><error-page> <error-code>404</error-code> <location>/WEB-INF/pages/errorPages/404.jsp</location></error-page><welcome-file-list> <welcome-file>login.jsp</welcome-file></welcome-file-list><servlet> <servlet-name>DisplayChart</servlet-name> <servlet-class>org.jfree.chart.servlet.DisplayChart</servlet-class></servlet><servlet-mapping> <servlet-name>DisplayChart</servlet-name> <url-pattern>/DisplayChart</url-pattern></servlet-mapping></web-app>