<?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>
    <parent>
        <groupId>org.springframework.boot</groupId>
        <artifactId>spring-boot-starter-parent</artifactId>
        <version>2.7.0</version>
        <relativePath>/storlead-dependencies/pom.xml</relativePath> <!-- 或者默认 -->
    </parent>

    <groupId>com.storlead.boot</groupId>
    <artifactId>storlead-centre-platform</artifactId>
    <version>${revision}</version>
    <packaging>pom</packaging>
    <name>storlead-centre-platform</name>

    <modules>
        <module>storlead-dependencies</module>
        <module>storlead-framework</module>
        <module>storlead-centre-api</module>
        <module>storlead-centre-service</module>
        <module>storlead-wx</module>
        <module>storlead-user</module>
        <module>storlead-sms</module>
    </modules>

    <properties>
        <revision>1.0</revision>
        <java.version>17</java.version>
        <maven.compiler.source>${java.version}</maven.compiler.source>
        <maven.compiler.target>${java.version}</maven.compiler.target>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <!--全局配置项目版本号-->
        <jwt.version>0.9.1</jwt.version>
        <commons.version>2.6</commons.version>
        <!-- 表示打包时跳过mvn test -->
        <maven.test.skip>true</maven.test.skip>
        <aviator.version>5.2.7</aviator.version>
        <io.jsonwebtoken.version>0.9.1</io.jsonwebtoken.version>
        <logstash-logback.version>6.6</logstash-logback.version>

        <maven-surefire-plugin.version>3.0.0-M5</maven-surefire-plugin.version>
        <maven-compiler-plugin.version>3.0</maven-compiler-plugin.version>
        <flatten-maven-plugin.version>1.6.0</flatten-maven-plugin.version>
        <lombok.version>1.18.36</lombok.version>
        <spring.boot.version>2.7.0</spring.boot.version>
        <mapstruct.version>1.6.3</mapstruct.version>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    </properties>

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>com.storlead.boot</groupId>
                <artifactId>storlead-dependencies</artifactId>
                <version>${revision}</version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>
        </dependencies>
    </dependencyManagement>

    <build>
        <pluginManagement>
            <plugins>
                <!-- maven-surefire-plugin 插件，用于运行单元测试。 -->
                <!-- 注意，需要使用 3.0.X+，因为要支持 Junit 5 版本 -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-surefire-plugin</artifactId>
                    <version>${maven-surefire-plugin.version}</version>
                </plugin>
                <!-- maven-compiler-plugin 插件，解决 spring-boot-configuration-processor + Lombok + MapStruct 组合 -->
                <!-- https://stackoverflow.com/questions/33483697/re-run-spring-boot-configuration-annotation-processor-to-update-generated-metada -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-compiler-plugin</artifactId>
                    <version>${maven-compiler-plugin.version}</version>
                    <configuration>
<!--                        <configuration>-->
<!--                            <source>17</source>-->
<!--                            <target>17</target>-->
<!--                        </configuration>-->
<!--                        <annotationProcessorPaths>-->
<!--                            <path>-->
<!--                                <groupId>org.springframework.boot</groupId>-->
<!--                                <artifactId>spring-boot-configuration-processor</artifactId>-->
<!--                                <version>${spring.boot.version}</version>-->
<!--                            </path>-->
<!--                            <path>-->
<!--                                <groupId>org.projectlombok</groupId>-->
<!--                                <artifactId>lombok</artifactId>-->
<!--                                <version>${lombok.version}</version>-->
<!--                            </path>-->
<!--                            <path>-->
<!--                                <groupId>org.mapstruct</groupId>-->
<!--                                <artifactId>mapstruct-processor</artifactId>-->
<!--                                <version>${mapstruct.version}</version>-->
<!--                            </path>-->
<!--                        </annotationProcessorPaths>-->
                    </configuration>
                </plugin>
            </plugins>
        </pluginManagement>
    </build>


    <repositories>
        <repository>
            <id>aliyunmaven</id>
            <name>aliyun</name>
            <url>https://maven.aliyun.com/repository/public</url>
        </repository>

        <repository>
            <id>spring-milestones</id>
            <name>Spring Milestones</name>
            <url>https://repo.spring.io/milestone</url>
            <snapshots>
                <enabled>false</enabled>
            </snapshots>
        </repository>
        <repository>
            <id>spring-snapshots</id>
            <name>Spring Snapshots</name>
            <url>https://repo.spring.io/snapshot</url>
            <releases>
                <enabled>false</enabled>
            </releases>
        </repository>
    </repositories>
</project>
