Blame view

WebRoot/WEB-INF/web.xml 4.08 KB
ad5081d3   孙向锦   初始化项目
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
  <?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/javaee"
  	xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
  	version="2.5">
  		
  	<context-param>
  		<param-name>contextConfigLocation</param-name>
  		<param-value>
  			classpath:spring/ApplicationContext-main.xml,
  			classpath:spring/ApplicationContext-dataSource.xml,
  			classpath:spring/ApplicationContext-shiro.xml,
  			classpath:spring/ApplicationContext-redis.xml
  		</param-value>
  	</context-param>
  	<context-param>
  		<param-name>log4jConfigLocation</param-name>
  		<param-value>classpath:log4j.properties</param-value>
  	</context-param>
  	<filter>
  		<filter-name>encodingFilter</filter-name>
  		<filter-class>org.springframework.web.filter.CharacterEncodingFilter</filter-class>
  		<init-param>
  			<param-name>encoding</param-name>
  			<param-value>utf-8</param-value>
  		</init-param>
  	</filter>
  	<filter-mapping>
  		<filter-name>encodingFilter</filter-name>
  		<url-pattern>/*</url-pattern>
  	</filter-mapping>
  	<context-param>
  		<param-name>webAppRootKey</param-name>
  		<param-value>www.fhadmin.org</param-value>
  	</context-param>
  
  	<!-- 连接池 启用Web监控统计功能   start-->
  	<filter>
  		<filter-name>DruidWebStatFilter</filter-name>
  		<filter-class>com.alibaba.druid.support.http.WebStatFilter</filter-class>
  		<init-param>
  			<param-name>exclusions</param-name>
  			<param-value>*.js,*.gif,*.jpg,*.png,*.css,*.ico,/druid/*</param-value>
  		</init-param>
  	</filter>
  	<filter-mapping>
  		<filter-name>DruidWebStatFilter</filter-name>
  		<url-pattern>/*</url-pattern>
  	</filter-mapping>
  	<servlet>
  		<servlet-name>DruidStatView</servlet-name>
  		<servlet-class>com.alibaba.druid.support.http.StatViewServlet</servlet-class>
  	</servlet>
  	<servlet-mapping>
  		<servlet-name>DruidStatView</servlet-name>
  		<url-pattern>/druid/*</url-pattern>
  	</servlet-mapping>
  	<!-- 连接池 启用Web监控统计功能   end-->
  
  	<filter>
  		<filter-name>loginFilter</filter-name>
  		<filter-class>com.fh.filter.LoginFilter</filter-class>
  	</filter>
  	<listener>
  		<listener-class>org.springframework.web.util.Log4jConfigListener</listener-class>
  	</listener>
  	<listener>
  		<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
  	</listener>
  	
  	<servlet>
  		<servlet-name>springMvc</servlet-name>
  		<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
  		<init-param>
  			<param-name>contextConfigLocation</param-name>
  			<param-value>classpath:spring/ApplicationContext-mvc.xml</param-value>
  		</init-param>
  		<load-on-startup>1</load-on-startup>
  	</servlet>
  	<servlet-mapping>
  		<servlet-name>springMvc</servlet-name>
  		<url-pattern>/</url-pattern>
  	</servlet-mapping>
  	
  	<!-- tomcat等 启动之前执行 -->
  	<filter>
  		<filter-name>startFilter</filter-name>
  		<filter-class>com.fh.filter.startFilter</filter-class>
  	</filter>
  	
  	<!-- Shiro filter start -->
  	<filter>
  		<filter-name>shiroFilter</filter-name>
794ac27e   孙向锦   修改为中天教育
94
  		<filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>
ad5081d3   孙向锦   初始化项目
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
  		<init-param>
  			<param-name>targetFilterLifecycle</param-name>
  			<param-value>true</param-value>
  		</init-param>
  	</filter>
  	<filter-mapping>
  		<filter-name>shiroFilter</filter-name>
  		<url-pattern>/*</url-pattern>
  	</filter-mapping>
  	<!-- Shiro filter end -->
  	
  
  	<error-page>
  		<error-code>404</error-code>
  		<location>/404.jsp</location>
  	</error-page>
  	
  <!--
  	 <error-page>
  	    <error-code>405</error-code>
  	   <location>/WEB-INF/405.html</location>
  	 </error-page>
  	 <error-page>
  	   <error-code>404</error-code>
  	   <location>/WEB-INF/404.html</location>
  	 </error-page>
  	 <error-page>
  	   <error-code>500</error-code>
  	   <location>/WEB-INF/500.html</location>
  	 </error-page>
  	 <error-page>
  	   <error-code>javax.servle.ServletException</error-code>
  	   <location>/WEB-INF/error.html</location>
  	 </error-page>
  	 <error-page>
  	   <error-code>java.lang.NullPointerException</error-code>
  	   <location>/WEB-INF/error.html</location>
  	 </error-page>
  -->
  	<session-config>
  		<session-timeout>600</session-timeout>
  	</session-config>
  </web-app>