-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathpom.xml
More file actions
247 lines (212 loc) · 9.64 KB
/
pom.xml
File metadata and controls
247 lines (212 loc) · 9.64 KB
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
94
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
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
<!-- pom模型版本 -->
<modelVersion>4.0.0</modelVersion>
<!-- 项目的打包类型 -->
<!-- pom jar war --><!-- 默认是打包成jar包 -->
<packaging>jar</packaging>
<!-- parent -->
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>2.4.2</version>
<relativePath/> <!-- lookup parent from repository -->
</parent>
<!-- 项目信息 -->
<groupId>com.7-react-admin-java</groupId><!-- 项目唯一标识 -->
<artifactId>7-react-admin-java</artifactId><!-- 项目名 -->
<version>0.0.1-SNAPSHOT</version><!-- 版本 -->
<name>7-react-admin-java</name><!-- 项目的名称, Maven 产生的文档用 -->
<description>7-react-admin-java</description><!-- 项目的描述, Maven 产生的文档用 -->
<!-- 属性设置 -->
<properties>
<java.version>1.8</java.version><!-- jdK版本 -->
<!-- 除了修改version还可以在properties中来修改依赖的版本号 -->
<!-- <mysql.version>8.0.21</mysql.version> -->
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding><!-- 编译字符编码为utf-8 -->
<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding><!-- 输出字符编码为UTF-8 -->
<!-- 打包时跳过test检查 -->
<!-- maven方式跳过maven test, 等同$ mvn package -Dmaven.test.skip=true -->
<!-- <maven.test.skip>true</maven.test.skip> -->
<!-- surefire plugin方式跳过maven test, 等同$ mvn package -DskipTests -->
<!-- 一共有两种方式在打包时,跳过test,另一种是插件plugin中maven-surefire-plugin插件 -->
<skipTests>true</skipTests>
</properties>
<!-- 依赖关系 -->
<dependencies>
<!-- spring-boot-starter -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter</artifactId>
</dependency>
<!-- spring-boot-starter-web -->
<!-- web场景启动器 -->
<!-- 内置了 jackson -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<!-- spring-boot-starter-thymeleaf -->
<!-- 主要用于显示resources/templates中的html -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-thymeleaf</artifactId>
</dependency>
<!-- spring-boot-starter-validation -->
<!--校验组件-->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-validation</artifactId>
</dependency>
<!-- 安全框架 -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-security</artifactId>
</dependency>
<!-- JWT -->
<dependency>
<groupId>com.auth0</groupId>
<artifactId>java-jwt</artifactId>
<version>3.15.0</version>
</dependency>
<!-- mysql驱动 -->
<!-- mysql驱动注意点:( mysql驱动版本 ) 要和 ( mysql版本) 一致 -->
<!--- 利用mybatis操作mysql需要三个库 ( mysql + jdbc + mybatis ) -->
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>8.0.21</version>
<scope>runtime</scope>
</dependency>
<!-- jdbc依赖,(Java Database Connectivity) java数据连接 -->
<!-- <dependency>-->
<!-- <groupId>org.springframework.boot</groupId> -->
<!-- <artifactId>spring-boot-starter-jdbc</artifactId> -->
<!-- </dependency> -->
<!-- spring-boot-starter-data-jdbc -->
<!-- 注意区分 ( spring-boot-starter-data-jdbc ) 和 ( spring-boot-starter-jdbc ) -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-data-jdbc</artifactId>
</dependency>
<!-- mybatis -->
<dependency>
<groupId>org.mybatis.spring.boot</groupId>
<artifactId>mybatis-spring-boot-starter</artifactId>
<version>2.1.3</version>
</dependency>
<!-- mybatis plus -->
<!-- mybatis plus包含了 ( mybatis-spring-boot-starter ) 和 ( spring-boot-starter-data-jdbc ) -->
<!-- 在 application.yml 文件中通过 mybatis-plus: xxx 对其进行定制配置 -->
<!-- SqlSessionFactory:自动在容器中配置好了,底层是容器中的默认数据源 -->
<!-- SqlSessionTemplate:自动在容器中配置好了 -->
<!-- @Mapper 标注也会被自动扫描-->
<dependency>
<groupId>com.baomidou</groupId>
<artifactId>mybatis-plus-boot-starter</artifactId>
<version>3.4.2</version>
</dependency>
<!-- redis -->
<!-- framework 是框架,架构的意思 -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-data-redis</artifactId>
</dependency>
<!-- jedis -->
<!-- SpringBoot默认使用的是Lettuce,要切换成jedis就必须安装该依赖 -->
<!-- redis的两种连接工厂, Lettuce 和 jedis -->
<dependency>
<groupId>redis.clients</groupId>
<artifactId>jedis</artifactId>
</dependency>
<!-- Swagger -->
<!-- 自动生成 ( 接口文档 ) 及 ( 自测工具 ) -->
<!-- Swagger2 3.0 只需要 ( springfox-boot-starter ) 就可以了 -->
<!-- Swagger2 2.x 则需要 ( springfox-swagger2 ) 和 ( springfox-swagger-ui )-->
<dependency>
<groupId>io.springfox</groupId>
<artifactId>springfox-boot-starter</artifactId>
<version>3.0.0</version>
</dependency>
<!-- (1) springfox-swagger2 -->
<!--<dependency>-->
<!--<groupId>io.springfox</groupId>-->
<!--<artifactId>springfox-swagger2</artifactId>-->
<!--<version>3.0.0</version>-->
<!--</dependency>-->
<!-- (2) springfox-swagger-ui -->
<!--dependency>-->
<!--<groupId>io.springfox</groupId>-->
<!--<artifactId>springfox-swagger-ui</artifactId>-->
<!--<version>3.0.0</version>-->
<!--</dependency>-->
<!-- spring-boot-devtools 热更新 -->
<!-- 要实现热更新还需要设置两个地方,具体见我的博客 -->
<!-- 博客地址:https://juejin.cn/post/6929145638898794503 -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-devtools</artifactId>
<scope>runtime</scope>
<optional>true</optional>
</dependency>
<!-- lombok -->
<!-- 主要用于自动生成DTO,MODEL,bean对象等的 @Getter @Setter @ToString @EqualsAndHashCode @RequiredArgsConstructor -->
<!-- Lombok 的 scope=provided,说明它只在编译阶段生效,不需要打入包中 -->
<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<version>1.18.16</version>
<scope>provided</scope>
</dependency>
<!-- fastjson 用于参数类型转换 -->
<!--<dependency>-->
<!--<groupId>com.alibaba</groupId>-->
<!--<artifactId>fastjson</artifactId>-->
<!--<version>1.2.57</version>-->
<!--</dependency>-->
<!-- 这里我们用了 Spring-boot-start-web 所以不需要在安装 pring-boot-starter-json 来使用 jackson -->
<!-- spring-boot-starter-test -->
<!-- 单元测试 场景启动器 -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-test</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
<!-- dependencyManagement 只是声明依赖,并不导入到package,子模块需要显示的引入 -->
<!-- <dependencyManagement>-->
<!-- <dependencies>-->
<!-- <dependency>-->
<!-- <groupId></groupId>-->
<!-- <artifactId></artifactId>-->
<!-- </dependency>-->
<!-- </dependencies>-->
<!-- </dependencyManagement>-->
<!-- 编译 -->
<build>
<!-- 插件 -->
<plugins>
<!-- maven插件 -->
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
</plugin>
<!-- maven-resources-plugin 打包成 fat jars 必须要用到的plugin -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-resources-plugin</artifactId>
<version>3.1.0</version>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<!-- 打包时跳过检查 -->
<!-- surefire 是万全,可靠的意思 -->
<configuration>
<skip>true</skip>
</configuration>
</plugin>
</plugins>
</build>
</project>