web.xml 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://xmlns.jcp.org/xml/ns/javaee" xmlns:jsp="http://java.sun.com/xml/ns/javaee/jsp" xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd" version="3.1">
  3. <display-name>Digital education management system</display-name>
  4. <context-param>
  5. <param-name>contextConfigLocation</param-name>
  6. <param-value>
  7. classpath:conf/druid.xml
  8. classpath:conf/spring-config.xml
  9. classpath:conf/spring-redis.xml
  10. </param-value>
  11. </context-param>
  12. <context-param>
  13. <param-name>webAppRootKey</param-name>
  14. <param-value>cs_core.root</param-value>
  15. </context-param>
  16. <context-param>
  17. <param-name>log4jConfigLocation</param-name>
  18. <param-value>classpath:conf/log4j.properties</param-value>
  19. </context-param>
  20. <servlet>
  21. <servlet-name>dispatcherServlet</servlet-name>
  22. <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
  23. <init-param>
  24. <param-name>contextConfigLocation</param-name>
  25. <param-value>classpath:conf/spring-mvc.xml</param-value>
  26. </init-param>
  27. <async-supported>true</async-supported>
  28. </servlet>
  29. <!-- CXFS -->
  30. <servlet>
  31. <servlet-name>CXFServlet</servlet-name>
  32. <servlet-class>
  33. org.apache.cxf.transport.servlet.CXFServlet
  34. </servlet-class>
  35. <load-on-startup>1</load-on-startup>
  36. </servlet>
  37. <servlet-mapping>
  38. <servlet-name>CXFServlet</servlet-name>
  39. <url-pattern>/webservice/*</url-pattern>
  40. </servlet-mapping>
  41. <servlet-mapping>
  42. <servlet-name>dispatcherServlet</servlet-name>
  43. <url-pattern>*.cs</url-pattern>
  44. </servlet-mapping>
  45. <filter>
  46. <filter-name>springSessionRepositoryFilter</filter-name>
  47. <filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>
  48. </filter>
  49. <filter-mapping>
  50. <filter-name>springSessionRepositoryFilter</filter-name>
  51. <url-pattern>/*</url-pattern>
  52. </filter-mapping>
  53. <filter>
  54. <filter-name>openSessionInViewFilter</filter-name>
  55. <filter-class>org.springframework.orm.hibernate4.support.OpenSessionInViewFilter</filter-class>
  56. </filter>
  57. <filter-mapping>
  58. <filter-name>openSessionInViewFilter</filter-name>
  59. <url-pattern>/*</url-pattern>
  60. </filter-mapping>
  61. <listener>
  62. <listener-class>org.springframework.web.util.Log4jConfigListener</listener-class>
  63. </listener>
  64. <listener>
  65. <listener-class>org.cs.notify.RequestListener</listener-class>
  66. </listener>
  67. <filter>
  68. <filter-name>encodingFilter</filter-name>
  69. <filter-class>org.springframework.web.filter.CharacterEncodingFilter</filter-class>
  70. <init-param>
  71. <param-name>encoding</param-name>
  72. <param-value>utf-8</param-value>
  73. </init-param>
  74. <init-param>
  75. <param-name>forceEncoding</param-name>
  76. <param-value>true</param-value>
  77. </init-param>
  78. </filter>
  79. <filter-mapping>
  80. <filter-name>encodingFilter</filter-name>
  81. <url-pattern>/*</url-pattern>
  82. </filter-mapping>
  83. <listener>
  84. <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
  85. </listener>
  86. <jsp-config>
  87. <taglib>
  88. <taglib-uri>http://www.test.com/jsp/permission</taglib-uri>
  89. <taglib-location>/WEB-INF/tags/permission.tld</taglib-location>
  90. </taglib>
  91. </jsp-config>
  92. <session-config>
  93. <session-timeout>600</session-timeout>
  94. </session-config>
  95. <error-page>
  96. <error-code>404</error-code>
  97. <location>/common/404.html</location>
  98. </error-page>
  99. <error-page>
  100. <error-code>500</error-code>
  101. <location>/common/500.html</location>
  102. </error-page>
  103. <welcome-file-list>
  104. <welcome-file>app/login/login.jsp</welcome-file>
  105. </welcome-file-list>
  106. </web-app>