Skip to content

Commit e579ef0

Browse files
committed
add spring demo initial
1 parent 7deb25b commit e579ef0

File tree

3 files changed

+81
-0
lines changed

3 files changed

+81
-0
lines changed

pom.xml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,7 @@
3939
<module>weixin-java-common</module>
4040
<module>weixin-java-cp</module>
4141
<module>weixin-java-mp</module>
42+
<module>spring-demo</module>
4243
</modules>
4344

4445
<properties>

spring-demo/pom.xml

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
<?xml version="1.0"?>
2+
<project
3+
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
4+
xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
5+
<modelVersion>4.0.0</modelVersion>
6+
<parent>
7+
<groupId>com.github.binarywang</groupId>
8+
<artifactId>weixin-java-parent</artifactId>
9+
<version>1.3.5-SNAPSHOT</version>
10+
</parent>
11+
<artifactId>spring-demo</artifactId>
12+
<packaging>war</packaging>
13+
<name>WeiXin Java Tools - demo with spring</name>
14+
<description>spring demo</description>
15+
<url>https://github.com/binarywang/weixin-java-tools</url>
16+
17+
<dependencies>
18+
<dependency>
19+
<groupId>com.github.binarywang</groupId>
20+
<artifactId>weixin-java-common</artifactId>
21+
<version>${project.version}</version>
22+
</dependency>
23+
</dependencies>
24+
25+
</project>
Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<web-app xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3+
xmlns="http://java.sun.com/xml/ns/javaee" xmlns:web="http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"
4+
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd"
5+
version="3.0">
6+
<display-name>api</display-name>
7+
<context-param>
8+
<param-name>contextConfigLocation</param-name>
9+
<param-value>classpath:applicationContext.xml</param-value>
10+
</context-param>
11+
<filter>
12+
<filter-name>encodingFilter</filter-name>
13+
<filter-class>org.springframework.web.filter.CharacterEncodingFilter</filter-class>
14+
<init-param>
15+
<param-name>encoding</param-name>
16+
<param-value>UTF-8</param-value>
17+
</init-param>
18+
</filter>
19+
<filter-mapping>
20+
<filter-name>encodingFilter</filter-name>
21+
<url-pattern>/*</url-pattern>
22+
</filter-mapping>
23+
<filter>
24+
<filter-name>springSecurityFilterChain</filter-name>
25+
<filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>
26+
</filter>
27+
<filter-mapping>
28+
<filter-name>springSecurityFilterChain</filter-name>
29+
<url-pattern>/v1/admin/*</url-pattern>
30+
</filter-mapping>
31+
32+
<listener>
33+
<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
34+
</listener>
35+
<listener>
36+
<listener-class>org.springframework.web.util.IntrospectorCleanupListener</listener-class>
37+
</listener>
38+
<servlet>
39+
<description>spring mvc servlet</description>
40+
<servlet-name>springMvc</servlet-name>
41+
<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
42+
<init-param>
43+
<param-name>contextConfigLocation</param-name>
44+
<param-value>classpath:spring-servlet-common.xml</param-value>
45+
</init-param>
46+
<load-on-startup>1</load-on-startup>
47+
</servlet>
48+
<servlet-mapping>
49+
<servlet-name>springMvc</servlet-name>
50+
<url-pattern>/</url-pattern>
51+
</servlet-mapping>
52+
<session-config>
53+
<session-timeout>30</session-timeout>
54+
</session-config>
55+
</web-app>

0 commit comments

Comments
 (0)