<?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>
        <artifactId>fhzg</artifactId>
        <groupId>com.hdkj</groupId>
        <version>${revision}</version>
    </parent>

    <artifactId>services</artifactId>
    <packaging>pom</packaging>

    <modules>
        <module>ruoyi-job</module>
        <module>load-transfer-bf</module>
        <module>load-transfer-mq</module>
        <module>load-transfer-si</module>
        <module>load-transfer-io</module>
    </modules>

    <dependencies>
        <dependency>
            <groupId>com.hdkj</groupId>
            <artifactId>common-core</artifactId>
        </dependency>
        <dependency>
            <groupId>com.hdkj</groupId>
            <artifactId>ruoyi-common-core</artifactId>
        </dependency>
        <dependency>
            <groupId>com.hdkj</groupId>
            <artifactId>ruoyi-common-security</artifactId>
        </dependency>
        <dependency>
            <groupId>com.hdkj</groupId>
            <artifactId>ruoyi-common-datasource</artifactId>
        </dependency>
        <dependency>
            <groupId>com.hdkj</groupId>
            <artifactId>load-transfer-si-api</artifactId>
        </dependency>
        <dependency>
            <groupId>com.hdkj</groupId>
            <artifactId>load-transfer-mq-api</artifactId>
        </dependency>
        <dependency>
            <groupId>com.hdkj</groupId>
            <artifactId>load-transfer-bf-api</artifactId>
        </dependency>
        <dependency>
            <groupId>com.hdkj</groupId>
            <artifactId>load-transfer-io-api</artifactId>
        </dependency>
        <dependency>
            <groupId>com.hdkj</groupId>
            <artifactId>ruoyi-api-system</artifactId>
        </dependency>

<!--        <dependency>-->
<!--            <groupId>com.baomidou</groupId>-->
<!--            <artifactId>mybatis-plus-boot-starter</artifactId>-->
<!--        </dependency>-->

        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-data-redis</artifactId>
        </dependency>

        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-web</artifactId>
        </dependency>

        <dependency>
            <groupId>org.springframework.boot</groupId>
            <artifactId>spring-boot-starter-test</artifactId>
        </dependency>

        <dependency>
            <groupId>com.alibaba.cloud</groupId>
            <artifactId>spring-cloud-starter-alibaba-nacos-config</artifactId>
        </dependency>
        <dependency>
            <groupId>com.alibaba.cloud</groupId>
            <artifactId>spring-cloud-starter-alibaba-nacos-discovery</artifactId>
        </dependency>

        <dependency>
            <groupId>org.springframework.statemachine</groupId>
            <artifactId>spring-statemachine-starter</artifactId>
        </dependency>
        <dependency>
            <groupId>org.springframework.statemachine</groupId>
            <artifactId>spring-statemachine-kryo</artifactId>
        </dependency>
        <dependency>
            <groupId>com.mysql</groupId>
            <artifactId>mysql-connector-j</artifactId>
        </dependency>
        <dependency>
            <groupId>commons-beanutils</groupId>
            <artifactId>commons-beanutils</artifactId>
            <version>1.9.4</version>
        </dependency>
    </dependencies>

    <profiles>
        <profile>
            <!-- 本地环境 -->
            <id>local</id>
            <activation>
                <activeByDefault>true</activeByDefault>
            </activation>
            <properties>
                <environment>local</environment>
            </properties>
        </profile>
        <profile>
            <!-- 开发环境 -->
            <id>dev</id>
            <activation>
                <activeByDefault>false</activeByDefault>
            </activation>
            <properties>
                <environment>dev</environment>
            </properties>
        </profile>
        <profile>
            <!-- 测试环境 -->
            <id>test</id>
            <activation>
                <activeByDefault>false</activeByDefault>
            </activation>
            <properties>
                <environment>test</environment>
            </properties>
        </profile>
        <profile>
            <!-- UAT环境 -->
            <id>uat</id>
            <activation>
                <activeByDefault>false</activeByDefault>
            </activation>
            <properties>
                <environment>uat</environment>
            </properties>
        </profile>
        <profile>
            <!-- 生产环境 -->
            <id>prod</id>
            <activation>
                <activeByDefault>false</activeByDefault>
            </activation>
            <properties>
                <environment>prod</environment>
            </properties>
        </profile>
    </profiles>


    <build>
        <resources>
            <resource>
                <!-- 指定配置文件所在的resources目录 -->
                <directory>src/main/resources</directory>
                <includes>
                    <include>bootstrap.yaml</include>
                    <include>bootstrap-${environment}.yaml</include>
                    <include>bootstrap.yml</include>
                    <include>kaptcha.properties</include>
                    <include>log4j2.xml</include>
                    <include>sentinel.properties</include>
                </includes>
                <filtering>true</filtering>
            </resource>
            <resource>
                <!-- 把被激活环境下的配置文件都编译到classpath下 -->
                <directory>src/main/resources/config/${environment}</directory>
            </resource>
            <resource>
                <!-- 打包MyBatis XML文件所在的目录 -->
                <directory>src/main/resources</directory>
                <includes>
                    <include>mapper/*.xml</include>
                </includes>
            </resource>
            <resource>
                <directory>src/main/java</directory>
                <includes>
                    <include>com/hdkj/**/mapping/*.xml</include>
                </includes>
            </resource>
            <resource>
                <!-- 模板打包到template -->
                <directory>src/main/resources/template</directory>
                <targetPath>template/</targetPath>
                <includes>
                    <include>**/*</include>
                </includes>
            </resource>
        </resources>
        <plugins>
            <plugin>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-maven-plugin</artifactId>
                <version>${spring-boot.version}</version>
                <configuration>
                    <includeSystemScope>true</includeSystemScope>
                </configuration>
                <executions>
                    <execution>
                        <goals>
                            <goal>repackage</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>3.8.1</version>
                <configuration>
                    <source>${java.version}</source>
                    <target>${java.version}</target>
                    <encoding>${project.build.sourceEncoding}</encoding>
                    <compilerArgs>
                        <arg>-parameters</arg>
                    </compilerArgs>
                </configuration>
            </plugin>
        </plugins>

    </build>

</project>
