pom.xml 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <project xmlns="http://maven.apache.org/POM/4.0.0"
  3. xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  4. xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
  5. <modelVersion>4.0.0</modelVersion>
  6. <parent>
  7. <groupId>org.springframework.boot</groupId>
  8. <artifactId>spring-boot-dependencies</artifactId>
  9. <version>3.3.0</version>
  10. <relativePath/>
  11. </parent>
  12. <groupId>com.github.microservice</groupId>
  13. <artifactId>MSConfigure</artifactId>
  14. <version>1.0.0-SNAPSHOT</version>
  15. <packaging>pom</packaging>
  16. <properties>
  17. <!-- 项目编码 -->
  18. <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
  19. <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
  20. <!--JDK版本-->
  21. <java.version>17</java.version>
  22. <!-- spring boot -->
  23. <spring-boot.version>3.3.0</spring-boot.version>
  24. <!-- spring mvc -->
  25. <spring-mvc.version>6.1.8</spring-mvc.version>
  26. <spring-integration-core.version>6.3.0</spring-integration-core.version>
  27. <!-- spring cloud -->
  28. <spring-cloud-dependencies.version>2023.0.1</spring-cloud-dependencies.version>
  29. <spring-cloud.version>4.1.2</spring-cloud.version>
  30. <spring-cloud-starter-stream.version>4.1.1</spring-cloud-starter-stream.version>
  31. <spring-cloud-bus.version>4.1.1</spring-cloud-bus.version>
  32. <spring-cloud-starter-config.version>4.1.1</spring-cloud-starter-config.version>
  33. <spring-cloud-starter-consul-discovery.version>4.1.1</spring-cloud-starter-consul-discovery.version>
  34. <spring-cloud-gateway.version>4.1.2</spring-cloud-gateway.version>
  35. <netflix-hystrix.version>2.2.10.RELEASE</netflix-hystrix.version>
  36. <netflix-ribbon.version>2.2.10.RELEASE</netflix-ribbon.version>
  37. <!-- jpa -->
  38. <spring-boot-starter-data-jpa.version>3.3.0</spring-boot-starter-data-jpa.version>
  39. <spring-data-jpa.version>3.3.0</spring-data-jpa.version>
  40. <!-- 其他库 -->
  41. <groovy.version>4.0.21</groovy.version>
  42. <ehcache.version>3.10.8</ehcache.version>
  43. <caffeine.version>3.1.8</caffeine.version>
  44. <lombok.version>1.18.32</lombok.version>
  45. <httpclient.version>4.5.14</httpclient.version>
  46. <commons-lang3.version>3.14.0</commons-lang3.version>
  47. <junit.version>4.13.2</junit.version>
  48. <javax.servlet.jsp-api.version>2.3.3</javax.servlet.jsp-api.version>
  49. <servlets-ssi.version>5.0.16</servlets-ssi.version>
  50. <!--
  51. springboot3 弃用
  52. <javax.servlet-api.version>4.0.1</javax.servlet-api.version>
  53. -->
  54. <commons-fileupload.version>1.5</commons-fileupload.version>
  55. <jstl.version>1.2</jstl.version>
  56. <gson.version>2.11.0</gson.version>
  57. <jackson.version>2.17.1</jackson.version>
  58. <commons-beanutils.version>1.9.4</commons-beanutils.version>
  59. <hibernate.version>6.5.2.Final</hibernate.version>
  60. <jaxb-api.version>2.3.1</jaxb-api.version>
  61. <javax.annotation-api.version>1.3.2</javax.annotation-api.version>
  62. <javassist.version>3.30.2-GA</javassist.version>
  63. <!--链路追踪-->
  64. <zipkin.version>2.2.8.RELEASE</zipkin.version>
  65. <!-- 插件 -->
  66. <maven-compiler-plugin.version>3.13.0</maven-compiler-plugin.version>
  67. <maven-war-plugin.version>3.4.0</maven-war-plugin.version>
  68. <maven-surefire-plugin.version>3.2.5</maven-surefire-plugin.version>
  69. <!--项目版本-->
  70. <Project.version>1.0.0-SNAPSHOT</Project.version>
  71. <Project.groupId>com.github.microservice</Project.groupId>
  72. <!-- 注册发现服务端口 -->
  73. <ApplicationCenter.port>8500</ApplicationCenter.port>
  74. <!-- 网关端口-->
  75. <GetWayCenter.port>80</GetWayCenter.port>
  76. <!--开放平台-->
  77. <OpenApi.port>7900</OpenApi.port>
  78. <!-- 配置中心 -->
  79. <ConfigCenter.port>8000</ConfigCenter.port>
  80. <!--用户中心-->
  81. <UserCenter.port>8100</UserCenter.port>
  82. <!--推送中心-->
  83. <PushCenter.port>8300</PushCenter.port>
  84. <!--文件中心-->
  85. <FileCenter.port>8400</FileCenter.port>
  86. <!--机器人验证码端口-->
  87. <RobotFirewall.port>8600</RobotFirewall.port>
  88. <!--权限中心-->
  89. <AuthCenter.port>8700</AuthCenter.port>
  90. <!--MQ中心-->
  91. <MQCenter.port>8800</MQCenter.port>
  92. <!--支付中心-->
  93. <PayCenter.port>8900</PayCenter.port>
  94. </properties>
  95. <profiles>
  96. <!--开发环境-->
  97. <profile>
  98. <id>dev</id>
  99. <activation>
  100. <activeByDefault>true</activeByDefault>
  101. </activation>
  102. <properties>
  103. <spring.profiles.active>dev</spring.profiles.active>
  104. <ApplicationCenter.url>192.168.31.132:8500,192.168.31.132:8501,192.168.31.132:8502
  105. </ApplicationCenter.url>
  106. <ConfigCenter.url>http://127.0.0.1:${ConfigCenter.port}</ConfigCenter.url>
  107. <Kafka.brokers>192.168.31.132:9092</Kafka.brokers>
  108. <Zipkin.baseUrl>http://192.168.110.241:9411</Zipkin.baseUrl>
  109. <Zipkin.sampler.probability>0.01</Zipkin.sampler.probability>
  110. </properties>
  111. </profile>
  112. <!--测试环境-->
  113. <profile>
  114. <id>test</id>
  115. <properties>
  116. <spring.profiles.active>test</spring.profiles.active>
  117. <ApplicationCenter.url>192.168.63.132</ApplicationCenter.url>
  118. <ConfigCenter.url>http://192.168.63.132:${ConfigCenter.port}</ConfigCenter.url>
  119. <Kafka.brokers>192.168.63.132:9092,192.168.63.132:9093,192.168.63.132:9094</Kafka.brokers>
  120. <Zipkin.baseUrl>http://192.168.63.132:9411</Zipkin.baseUrl>
  121. <Zipkin.sampler.probability>0.01</Zipkin.sampler.probability>
  122. </properties>
  123. </profile>
  124. <!--生产环境-->
  125. <profile>
  126. <id>prod</id>
  127. <properties>
  128. <spring.profiles.active>prod</spring.profiles.active>
  129. <ApplicationCenter.url>172.24.50.47:8500,172.24.50.47:8501,172.24.50.47:8502</ApplicationCenter.url>
  130. <ConfigCenter.url>http://172.24.50.47:${ConfigCenter.port}</ConfigCenter.url>
  131. <Kafka.brokers>172.24.50.52:9092</Kafka.brokers>
  132. <Zipkin.baseUrl>http://172.24.50.52:9411</Zipkin.baseUrl>
  133. <Zipkin.sampler.probability>0.01</Zipkin.sampler.probability>
  134. </properties>
  135. </profile>
  136. </profiles>
  137. <!--依赖-->
  138. <dependencies>
  139. <!-- spring boot -->
  140. <!--tomcat运行环境-->
  141. <dependency>
  142. <groupId>org.springframework.boot</groupId>
  143. <artifactId>spring-boot-starter-tomcat</artifactId>
  144. <version>${spring-boot.version}</version>
  145. </dependency>
  146. <!--自带web容器-->
  147. <dependency>
  148. <groupId>org.springframework.boot</groupId>
  149. <artifactId>spring-boot-starter-web</artifactId>
  150. <version>${spring-boot.version}</version>
  151. </dependency>
  152. <dependency>
  153. <groupId>org.springframework.boot</groupId>
  154. <artifactId>spring-boot-configuration-processor</artifactId>
  155. <version>${spring-boot.version}</version>
  156. <optional>true</optional>
  157. </dependency>
  158. <!--测试-->
  159. <dependency>
  160. <groupId>org.springframework.boot</groupId>
  161. <artifactId>spring-boot-starter-test</artifactId>
  162. <version>${spring-boot.version}</version>
  163. <scope>test</scope>
  164. </dependency>
  165. <!-- gson -->
  166. <dependency>
  167. <groupId>com.google.code.gson</groupId>
  168. <artifactId>gson</artifactId>
  169. <version>${gson.version}</version>
  170. </dependency>
  171. <!--Spring mvc-->
  172. <dependency>
  173. <groupId>org.springframework</groupId>
  174. <artifactId>spring-orm</artifactId>
  175. <version>${spring-mvc.version}</version>
  176. </dependency>
  177. <dependency>
  178. <groupId>org.springframework</groupId>
  179. <artifactId>spring-core</artifactId>
  180. <version>${spring-mvc.version}</version>
  181. </dependency>
  182. <dependency>
  183. <groupId>org.springframework</groupId>
  184. <artifactId>spring-aop</artifactId>
  185. <version>${spring-mvc.version}</version>
  186. </dependency>
  187. <dependency>
  188. <groupId>org.springframework</groupId>
  189. <artifactId>spring-tx</artifactId>
  190. <version>${spring-mvc.version}</version>
  191. </dependency>
  192. <dependency>
  193. <groupId>org.springframework</groupId>
  194. <artifactId>spring-context</artifactId>
  195. <version>${spring-mvc.version}</version>
  196. </dependency>
  197. <dependency>
  198. <groupId>org.springframework</groupId>
  199. <artifactId>spring-context-support</artifactId>
  200. <version>${spring-mvc.version}</version>
  201. </dependency>
  202. <dependency>
  203. <groupId>org.springframework</groupId>
  204. <artifactId>spring-webmvc</artifactId>
  205. <version>${spring-mvc.version}</version>
  206. </dependency>
  207. <dependency>
  208. <groupId>org.springframework</groupId>
  209. <artifactId>spring-aspects</artifactId>
  210. <version>${spring-mvc.version}</version>
  211. </dependency>
  212. <dependency>
  213. <groupId>org.springframework</groupId>
  214. <artifactId>spring-beans</artifactId>
  215. <version>${spring-mvc.version}</version>
  216. </dependency>
  217. <dependency>
  218. <groupId>org.springframework</groupId>
  219. <artifactId>spring-expression</artifactId>
  220. <version>${spring-mvc.version}</version>
  221. </dependency>
  222. <dependency>
  223. <groupId>org.springframework</groupId>
  224. <artifactId>spring-oxm</artifactId>
  225. <version>${spring-mvc.version}</version>
  226. </dependency>
  227. <dependency>
  228. <groupId>org.springframework</groupId>
  229. <artifactId>spring-messaging</artifactId>
  230. <version>${spring-mvc.version}</version>
  231. </dependency>
  232. <dependency>
  233. <groupId>org.springframework</groupId>
  234. <artifactId>spring-web</artifactId>
  235. <version>${spring-mvc.version}</version>
  236. </dependency>
  237. <!-- 依赖包 -->
  238. <dependency>
  239. <groupId>javax.servlet</groupId>
  240. <artifactId>jstl</artifactId>
  241. <version>${jstl.version}</version>
  242. </dependency>
  243. <dependency>
  244. <groupId>commons-fileupload</groupId>
  245. <artifactId>commons-fileupload</artifactId>
  246. <version>${commons-fileupload.version}</version>
  247. </dependency>
  248. <!-- <dependency>-->
  249. <!-- <groupId>javax.servlet</groupId>-->
  250. <!-- <artifactId>javax.servlet-api</artifactId>-->
  251. <!-- <version>${javax.servlet-api.version}</version>-->
  252. <!-- </dependency>-->
  253. <dependency>
  254. <groupId>tomcat</groupId>
  255. <artifactId>servlets-ssi</artifactId>
  256. <version>${servlets-ssi.version}</version>
  257. </dependency>
  258. <dependency>
  259. <groupId>javax.servlet.jsp</groupId>
  260. <artifactId>javax.servlet.jsp-api</artifactId>
  261. <version>${javax.servlet.jsp-api.version}</version>
  262. </dependency>
  263. <dependency>
  264. <groupId>junit</groupId>
  265. <artifactId>junit</artifactId>
  266. <version>${junit.version}</version>
  267. </dependency>
  268. <dependency>
  269. <groupId>org.apache.commons</groupId>
  270. <artifactId>commons-lang3</artifactId>
  271. <version>${commons-lang3.version}</version>
  272. </dependency>
  273. <dependency>
  274. <groupId>org.apache.httpcomponents</groupId>
  275. <artifactId>httpclient</artifactId>
  276. <version>${httpclient.version}</version>
  277. </dependency>
  278. <dependency>
  279. <groupId>org.apache.groovy</groupId>
  280. <artifactId>groovy-all</artifactId>
  281. <version>${groovy.version}</version>
  282. <type>pom</type>
  283. </dependency>
  284. <!-- Get Set 需要IDE 安装 lombok plugin -->
  285. <dependency>
  286. <groupId>org.projectlombok</groupId>
  287. <artifactId>lombok</artifactId>
  288. <version>${lombok.version}</version>
  289. </dependency>
  290. <dependency>
  291. <groupId>javax.annotation</groupId>
  292. <artifactId>javax.annotation-api</artifactId>
  293. <version>${javax.annotation-api.version}</version>
  294. </dependency>
  295. <dependency>
  296. <groupId>org.javassist</groupId>
  297. <artifactId>javassist</artifactId>
  298. <version>${javassist.version}</version>
  299. </dependency>
  300. </dependencies>
  301. <!--Spring Cloud-->
  302. <dependencyManagement>
  303. <dependencies>
  304. <dependency>
  305. <groupId>org.springframework.cloud</groupId>
  306. <artifactId>spring-cloud-dependencies</artifactId>
  307. <version>${spring-cloud-dependencies.version}</version>
  308. <type>pom</type>
  309. <scope>import</scope>
  310. </dependency>
  311. </dependencies>
  312. </dependencyManagement>
  313. <repositories>
  314. <!-- 阿里-->
  315. <repository>
  316. <id>nexus</id>
  317. <name>nexus</name>
  318. <url>https://maven.aliyun.com/nexus/content/groups/public</url>
  319. <releases>
  320. <enabled>true</enabled>
  321. </releases>
  322. <snapshots>
  323. <enabled>true</enabled>
  324. <updatePolicy>always</updatePolicy>
  325. </snapshots>
  326. </repository>
  327. <repository>
  328. <id>spring-snapshots</id>
  329. <name>Spring Snapshots</name>
  330. <url>https://repo.spring.io/snapshot</url>
  331. <snapshots>
  332. <enabled>true</enabled>
  333. </snapshots>
  334. </repository>
  335. <repository>
  336. <id>spring-milestones</id>
  337. <name>Spring Milestones</name>
  338. <url>https://repo.spring.io/milestone</url>
  339. <snapshots>
  340. <enabled>false</enabled>
  341. </snapshots>
  342. </repository>
  343. </repositories>
  344. <pluginRepositories>
  345. <pluginRepository>
  346. <id>groovy-plugins-release</id>
  347. <url>https://groovy.jfrog.io/artifactory/plugins-release</url>
  348. </pluginRepository>
  349. </pluginRepositories>
  350. <!--构建-->
  351. <build>
  352. <plugins>
  353. <!--支持yaml读取pom的参数-->
  354. <plugin>
  355. <groupId>org.apache.maven.plugins</groupId>
  356. <artifactId>maven-resources-plugin</artifactId>
  357. <version>3.3.1</version>
  358. <configuration>
  359. <encoding>UTF-8</encoding>
  360. <delimiters>
  361. <delimiter>@</delimiter>
  362. </delimiters>
  363. <useDefaultDelimiters>true</useDefaultDelimiters>
  364. <nonFilteredFileExtensions>
  365. <nonFilteredFileExtension>xlsx</nonFilteredFileExtension>
  366. <nonFilteredFileExtension>xls</nonFilteredFileExtension>
  367. <nonFilteredFileExtension>zip</nonFilteredFileExtension>
  368. <nonFilteredFileExtension>cer</nonFilteredFileExtension>
  369. <nonFilteredFileExtension>pfx</nonFilteredFileExtension>
  370. <nonFilteredFileExtension>py</nonFilteredFileExtension>
  371. <nonFilteredFileExtension>keystore</nonFilteredFileExtension>
  372. </nonFilteredFileExtensions>
  373. </configuration>
  374. </plugin>
  375. <plugin>
  376. <groupId>org.springframework.boot</groupId>
  377. <artifactId>spring-boot-maven-plugin</artifactId>
  378. <version>${spring-boot.version}</version>
  379. </plugin>
  380. <!-- groovy -->
  381. <plugin>
  382. <groupId>org.codehaus.gmavenplus</groupId>
  383. <artifactId>gmavenplus-plugin</artifactId>
  384. <version>2.1.0</version>
  385. <executions>
  386. <execution>
  387. <goals>
  388. <goal>addSources</goal>
  389. <goal>addTestSources</goal>
  390. <goal>generateStubs</goal>
  391. <goal>compile</goal>
  392. <goal>generateTestStubs</goal>
  393. <goal>compileTests</goal>
  394. <goal>removeStubs</goal>
  395. <goal>removeTestStubs</goal>
  396. </goals>
  397. </execution>
  398. </executions>
  399. <configuration>
  400. <sources>
  401. <source>
  402. <directory>${project.basedir}/src/main/java</directory>
  403. <includes>
  404. <include>**/*.groovy</include>
  405. </includes>
  406. </source>
  407. </sources>
  408. </configuration>
  409. </plugin>
  410. <plugin>
  411. <groupId>org.apache.maven.plugins</groupId>
  412. <artifactId>maven-compiler-plugin</artifactId>
  413. <version>${maven-compiler-plugin.version}</version>
  414. <configuration>
  415. <source>${java.version}</source>
  416. <target>${java.version}</target>
  417. <encoding>${project.build.sourceEncoding}</encoding>
  418. <useIncrementalCompilation>false</useIncrementalCompilation>
  419. <showDeprecation>true</showDeprecation>
  420. <showWarnings>true</showWarnings>
  421. </configuration>
  422. </plugin>
  423. <plugin>
  424. <artifactId>maven-war-plugin</artifactId>
  425. <version>${maven-war-plugin.version}</version>
  426. </plugin>
  427. <plugin>
  428. <groupId>org.apache.maven.plugins</groupId>
  429. <artifactId>maven-surefire-plugin</artifactId>
  430. <version>${maven-surefire-plugin.version}</version>
  431. <configuration>
  432. <skipTests>true</skipTests>
  433. </configuration>
  434. </plugin>
  435. </plugins>
  436. <!-- properties 取 pom 配置 -->
  437. <resources>
  438. <resource>
  439. <directory>src/main/resources</directory>
  440. <filtering>true</filtering>
  441. </resource>
  442. </resources>
  443. </build>
  444. </project>