<?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 http://maven.apache.org/xsd/maven-4.0.0.xsd">
	<modelVersion>4.0.0</modelVersion>
	<groupId>org.xyzh</groupId>
	<artifactId>school-news</artifactId>
	<packaging>pom</packaging>
	<version>1.0.0</version>

	<modules>
		<module>api</module>
		<module>auth</module>
		<module>system</module>
		<module>common</module>
		<module>admin</module>
		<module>news</module>
		<module>study</module>
		<module>usercenter</module>
		<module>achievement</module>
		<module>ai</module>
		<module>file</module>
		<module>crontab</module>
		<module>message</module>
	</modules>

	<properties>
		<school-news.version>1.0.0</school-news.version>
		<java.version>21</java.version>
		<maven.compiler.source>21</maven.compiler.source>
		<maven.compiler.target>21</maven.compiler.target>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>

		<spring-framework.version>6.2.10</spring-framework.version>
		<spring-boot.version>3.5.6</spring-boot.version>
		<spring-cloud.version>2025.0.0</spring-cloud.version>
		<spring-cloud-alibaba.version>2025.0.0.0-preview</spring-cloud-alibaba.version>

		<!-- 数据库依赖 -->
		<mysql.version>9.4.0</mysql.version>
		<hikaricp.version>7.0.2</hikaricp.version>
		<mybatis-plus.version>3.5.14</mybatis-plus.version>

		<fastjson.version>2.0.58</fastjson.version>
		<jakarta.servlet.version>6.1.0</jakarta.servlet.version>

		<!-- JWT 依赖版本 -->
		<jjwt.version>0.11.5</jjwt.version>

		<!-- BouncyCastle 依赖版本 -->
		<bouncycastle.version>1.82</bouncycastle.version>

		<!-- Log4j2 依赖版本 -->
		<log4j2.version>2.23.1</log4j2.version>

		<!-- Redis 依赖版本 -->
		<spring-data-redis.version>3.5.4</spring-data-redis.version>

		<!-- excel -->
		<poi.version>5.4.1</poi.version>

		<lombok.version>1.18.40</lombok.version>
	</properties>

	<dependencyManagement>
		<dependencies>
			<!-- school-news 系统 -->
			<dependency>
				<groupId>org.xyzh</groupId>
				<artifactId>api</artifactId>
				<version>1.0.0</version>
			</dependency>
			<dependency>
				<groupId>org.xyzh</groupId>
				<artifactId>common</artifactId>
				<version>1.0.0</version>
			</dependency>
			<dependency>
				<groupId>org.xyzh</groupId>
				<artifactId>common-all</artifactId>
				<version>1.0.0</version>
			</dependency>
			<dependency>
				<groupId>org.xyzh</groupId>
				<artifactId>auth</artifactId>
				<version>1.0.0</version>
			</dependency>
			<dependency>
				<groupId>org.xyzh</groupId>
				<artifactId>system</artifactId>
				<version>1.0.0</version>
			</dependency>
			<dependency>
				<groupId>org.xyzh</groupId>
				<artifactId>news</artifactId>
				<version>1.0.0</version>
			</dependency>
			<dependency>
				<groupId>org.xyzh</groupId>
				<artifactId>course</artifactId>
				<version>1.0.0</version>
			</dependency>
			<dependency>
				<groupId>org.xyzh</groupId>
				<artifactId>study</artifactId>
				<version>1.0.0</version>
			</dependency>
			<dependency>
				<groupId>org.xyzh</groupId>
				<artifactId>usercenter</artifactId>
				<version>1.0.0</version>
			</dependency>
			<dependency>
				<groupId>org.xyzh</groupId>
				<artifactId>achievement</artifactId>
				<version>1.0.0</version>
			</dependency>
			<dependency>
				<groupId>org.xyzh</groupId>
				<artifactId>ai</artifactId>
				<version>1.0.0</version>
			</dependency>
			<dependency>
				<groupId>org.xyzh</groupId>
				<artifactId>crontab</artifactId>
				<version>1.0.0</version>
			</dependency>
			<dependency>
				<groupId>org.xyzh</groupId>
				<artifactId>message</artifactId>
				<version>1.0.0</version>
			</dependency>
			<!-- Spring相关依赖 -->
			<!-- 覆盖SpringFramework的依赖配置-->
			<dependency>
				<groupId>org.springframework</groupId>
				<artifactId>spring-framework-bom</artifactId>
				<version>${spring-framework.version}</version>
				<type>pom</type>
				<scope>import</scope>
			</dependency>
			<!-- SpringBoot 依赖配置 -->
			<dependency>
				<groupId>org.springframework.boot</groupId>
				<artifactId>spring-boot-dependencies</artifactId>
				<version>${spring-boot.version}</version>
				<type>pom</type>
				<scope>import</scope>
			</dependency>
			<!-- SpringCloud 微服务 -->
			<dependency>
				<groupId>org.springframework.cloud</groupId>
				<artifactId>spring-cloud-dependencies</artifactId>
				<version>${spring-cloud.version}</version>
				<type>pom</type>
				<scope>import</scope>
			</dependency>

			<!-- SpringCloud Alibaba 微服务 -->
			<dependency>
				<groupId>com.alibaba.cloud</groupId>
				<artifactId>spring-cloud-alibaba-dependencies</artifactId>
				<version>${spring-cloud-alibaba.version}</version>
				<type>pom</type>
			</dependency>

			<!-- 数据库 -->
			<dependency>
				<groupId>org.springframework.boot</groupId>
				<artifactId>spring-boot-starter-jdbc</artifactId>
				<version>${spring-boot.version}</version>
			</dependency>
			<dependency>
				<groupId>com.mysql</groupId>
				<artifactId>mysql-connector-j</artifactId>
				<version>${mysql.version}</version>
				<scope>runtime</scope>
			</dependency>
			<dependency>
				<groupId>org.springframework.boot</groupId>
				<artifactId>spring-boot-starter-data-jdbc</artifactId>
				<version>${spring-boot.version}</version>
			</dependency>
			<dependency>
				<groupId>com.zaxxer</groupId>
				<artifactId>HikariCP</artifactId>
				<version>${hikaricp.version}</version>
			</dependency>

			<dependency>
				<groupId>com.baomidou</groupId>
				<artifactId>mybatis-plus-spring-boot3-starter</artifactId>
				<version>${mybatis-plus.version}</version>
			</dependency>

			<!-- JSON 解析器和生成器 -->
			<dependency>
				<groupId>com.alibaba.fastjson2</groupId>
				<artifactId>fastjson2</artifactId>
				<version>${fastjson.version}</version>
			</dependency>

			<dependency>
				<groupId>jakarta.servlet</groupId>
				<artifactId>jakarta.servlet-api</artifactId>
				<version>${jakarta.servlet.version}</version>
				<scope>provided</scope>
			</dependency>

			<dependency>
				<groupId>org.projectlombok</groupId>
				<artifactId>lombok</artifactId>
				<version>${lombok.version}</version>
				<scope>provided</scope>
			</dependency>

			<!-- JWT 依赖管理 -->
			<dependency>
				<groupId>io.jsonwebtoken</groupId>
				<artifactId>jjwt-api</artifactId>
				<version>${jjwt.version}</version>
			</dependency>
			<dependency>
				<groupId>io.jsonwebtoken</groupId>
				<artifactId>jjwt-impl</artifactId>
				<version>${jjwt.version}</version>
				<scope>runtime</scope>
			</dependency>
			<dependency>
				<groupId>io.jsonwebtoken</groupId>
				<artifactId>jjwt-jackson</artifactId>
				<version>${jjwt.version}</version>
				<scope>runtime</scope>
			</dependency>

			<!-- Log4j2 依赖管理 -->
			<dependency>
				<groupId>org.springframework.boot</groupId>
				<artifactId>spring-boot-starter-log4j2</artifactId>
				<version>${spring-boot.version}</version>
			</dependency>
			<dependency>
				<groupId>org.apache.logging.log4j</groupId>
				<artifactId>log4j-core</artifactId>
				<version>${log4j2.version}</version>
			</dependency>
			<dependency>
				<groupId>org.apache.logging.log4j</groupId>
				<artifactId>log4j-api</artifactId>
				<version>${log4j2.version}</version>
			</dependency>
			<dependency>
				<groupId>org.apache.logging.log4j</groupId>
				<artifactId>log4j-slf4j2-impl</artifactId>
				<version>${log4j2.version}</version>
			</dependency>
			<!-- Log4j2异步日志依赖 -->
			<dependency>
				<groupId>com.lmax</groupId>
				<artifactId>disruptor</artifactId>
				<version>3.4.4</version>
			</dependency>

			<!-- Redis 依赖管理 -->
			<dependency>
				<groupId>org.springframework.boot</groupId>
				<artifactId>spring-boot-starter-data-redis</artifactId>
				<version>${spring-boot.version}</version>
			</dependency>
			<dependency>
				<groupId>org.springframework.data</groupId>
				<artifactId>spring-data-redis</artifactId>
				<version>${spring-data-redis.version}</version>
			</dependency>

			<!-- excel -->
			<dependency>
				<groupId>org.apache.poi</groupId>
				<artifactId>poi</artifactId>
				<version>${poi.version}</version>
			</dependency>

			<dependency>
				<groupId>org.apache.poi</groupId>
				<artifactId>poi-ooxml</artifactId>
				<version>${poi.version}</version>
			</dependency>

		</dependencies>
	</dependencyManagement>
	<dependencies>
		<dependency>
			<groupId>org.springframework.cloud</groupId>
			<artifactId>spring-cloud-starter-bootstrap</artifactId>
			<!-- 排除默认的logback依赖 -->
			<exclusions>
				<exclusion>
					<groupId>org.springframework.boot</groupId>
					<artifactId>spring-boot-starter-logging</artifactId>
				</exclusion>
			</exclusions>
		</dependency>
		<dependency>
			<groupId>org.springframework.boot</groupId>
			<artifactId>spring-boot-starter-web</artifactId>
			<!-- 排除默认的logback依赖 -->
			<exclusions>
				<exclusion>
					<groupId>org.springframework.boot</groupId>
					<artifactId>spring-boot-starter-logging</artifactId>
				</exclusion>
			</exclusions>
		</dependency>
		<!-- 添加log4j2依赖 -->
		<dependency>
			<groupId>org.springframework.boot</groupId>
			<artifactId>spring-boot-starter-log4j2</artifactId>
		</dependency>
	</dependencies>
	<build>
		<plugins>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-compiler-plugin</artifactId>
				<configuration>
					<source>${java.version}</source>
					<target>${java.version}</target>
					<encoding>${project.build.sourceEncoding}</encoding>
					<compilerArgs>
						<arg>-J-Dfile.encoding=UTF-8</arg>
					</compilerArgs>
				</configuration>
			</plugin>
		</plugins>
		<pluginManagement>
			<plugins>
				<plugin>
					<groupId>org.springframework.boot</groupId>
					<artifactId>spring-boot-maven-plugin</artifactId>
					<version>${spring-boot.version}</version>
					<executions>
						<execution>
							<goals>
								<goal>repackage</goal>
							</goals>
						</execution>
					</executions>
				</plugin>
			</plugins>
		</pluginManagement>
	</build>

	<repositories>
		<!-- 阿里云镜像 -->
		<repository>
			<id>aliyun</id>
			<name>aliyun nexus</name>
			<url>https://maven.aliyun.com/repository/public</url>
			<releases>
				<enabled>true</enabled>
			</releases>
		</repository>
		<!-- Maven 中央仓库（备用） -->
		<repository>
			<id>central</id>
			<name>Maven Central</name>
			<url>https://repo.maven.apache.org/maven2</url>
			<releases>
				<enabled>true</enabled>
			</releases>
		</repository>
		<!-- Spring Milestone 仓库（备用） -->
		<repository>
			<id>spring-milestones</id>
			<name>Spring Milestones</name>
			<url>https://repo.spring.io/milestone</url>
			<releases>
				<enabled>true</enabled>
			</releases>
		</repository>
	</repositories>

	<pluginRepositories>
		<!-- 阿里云插件仓库 -->
		<pluginRepository>
			<id>aliyun</id>
			<name>aliyun nexus</name>
			<url>https://maven.aliyun.com/repository/public</url>
			<releases>
				<enabled>true</enabled>
			</releases>
			<snapshots>
				<enabled>false</enabled>
			</snapshots>
		</pluginRepository>
		<!-- Maven 中央仓库插件（备用） -->
		<pluginRepository>
			<id>central</id>
			<name>Maven Central</name>
			<url>https://repo.maven.apache.org/maven2</url>
			<releases>
				<enabled>true</enabled>
			</releases>
		</pluginRepository>
	</pluginRepositories>
</project>