<?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>com.sinszm</groupId>
    <artifactId>szm-boot</artifactId>
    <version>1.1.1.RELEASE</version>
    <packaging>pom</packaging>

    <name>szm-boot</name>
    <description>
        基于SpringBoot扩展生态微服务应用

        Copyright © 2020 智慧程序猿 All rights reserved.

        https://www.sinsz.com
    </description>

    <developers>
        <developer>
            <name>博学浮生</name>
            <email>admin@sinsz.com</email>
            <url>https://www.sinsz.com</url>
        </developer>
        <developer>
            <name>陈健波</name>
            <email>chenjianbo@sinszm.com</email>
            <url>https://www.sinsz.com</url>
        </developer>
    </developers>

    <organization>
        <name>SINSZM</name>
        <url>https://www.sinsz.com</url>
    </organization>

    <licenses>
        <license>
            <name>The MIT License (MIT)</name>
            <url>https://www.sinsz.com/LICENSE</url>
        </license>
    </licenses>

    <scm>
        <connection>scm:git:https://gitee.com/sinszm/szm-boot.git</connection>
        <developerConnection>scm:git:https://gitee.com/sinszm/szm-boot.git</developerConnection>
        <url>https://gitee.com/sinszm/szm-boot.git</url>
    </scm>

    <parent>
        <groupId>org.sonatype.oss</groupId>
        <artifactId>oss-parent</artifactId>
        <version>9</version>
    </parent>

    <!--配置模块-->
    <modules>
        <module>szm-boot-common</module>
        <module>szm-boot-basicwx</module>
        <module>szm-boot-mdb</module>
        <module>szm-boot-es</module>
        <module>szm-boot-web</module>
    </modules>

    <!--版本号配置-->
    <properties>
        <charset>UTF-8</charset>
        <project.build.sourceEncoding>${charset}</project.build.sourceEncoding>
        <project.reporting.outputEncoding>${charset}</project.reporting.outputEncoding>
        <java.version>1.8</java.version>
        <spring.boot.version>2.2.9.RELEASE</spring.boot.version>
        <platform.bom.version>Cairo-SR8</platform.bom.version>
        <nutz.version>1.r.68.v20200427</nutz.version>
        <mybatis.spring.boot.starter.version>2.1.2</mybatis.spring.boot.starter.version>
        <pagehelper.spring.boot.starter.version>1.2.13</pagehelper.spring.boot.starter.version>
        <tk.mybatis.version>2.1.5</tk.mybatis.version>
        <persistence.api.version>1.0.2</persistence.api.version>
        <gson.version>2.8.5</gson.version>
        <guava.version>23.0</guava.version>
        <dom4j.version>2.1.1</dom4j.version>
        <apache.httpclient.version>4.5.3</apache.httpclient.version>
        <swagger2.version>2.9.2</swagger2.version>
        <swagger2.ext.version>1.6.2</swagger2.ext.version>
        <swagger.ui.version>1.9.6</swagger.ui.version>
        <cxf.version>3.3.6</cxf.version>
        <hutool.version>5.4.3</hutool.version>
        <zxing.version>3.4.0</zxing.version>
        <cos.version>5.6.28</cos.version>
        <es.version>7.9.1</es.version>
        <jwt.version>3.11.0</jwt.version>

        <szm.boot.common.version>1.1.1.RELEASE</szm.boot.common.version>
        <szm.boot.web.version>1.1.1.RELEASE</szm.boot.web.version>
        <szm.boot.mdb.version>1.1.1.RELEASE</szm.boot.mdb.version>
        <szm.boot.basicwx.version>1.1.1.RELEASE</szm.boot.basicwx.version>
        <szm.boot.es.version>1.1.1.RELEASE</szm.boot.es.version>
    </properties>

    <!--配置所有依赖包-->
    <dependencyManagement>
        <dependencies>

            <dependency>
                <groupId>org.springframework.boot</groupId>
                <artifactId>spring-boot-dependencies</artifactId>
                <version>${spring.boot.version}</version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>

            <dependency>
                <groupId>io.spring.platform</groupId>
                <artifactId>platform-bom</artifactId>
                <version>${platform.bom.version}</version>
                <type>pom</type>
                <scope>import</scope>
            </dependency>

            <dependency>
                <groupId>org.nutz</groupId>
                <artifactId>nutz</artifactId>
                <version>${nutz.version}</version>
            </dependency>

            <dependency>
                <groupId>org.dom4j</groupId>
                <artifactId>dom4j</artifactId>
                <version>${dom4j.version}</version>
            </dependency>

            <dependency>
                <groupId>com.google.code.gson</groupId>
                <artifactId>gson</artifactId>
                <version>${gson.version}</version>
            </dependency>

            <dependency>
                <groupId>org.mybatis.spring.boot</groupId>
                <artifactId>mybatis-spring-boot-starter</artifactId>
                <version>${mybatis.spring.boot.starter.version}</version>
                <exclusions>
                    <exclusion>
                        <groupId>org.springframework.boot</groupId>
                        <artifactId>spring-boot-starter</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>

            <dependency>
                <groupId>tk.mybatis</groupId>
                <artifactId>mapper-spring-boot-starter</artifactId>
                <version>${tk.mybatis.version}</version>
                <exclusions>
                    <exclusion>
                        <groupId>org.mybatis</groupId>
                        <artifactId>*</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>org.springframework.boot</groupId>
                        <artifactId>*</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>javax.persistence</groupId>
                        <artifactId>persistence-api</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>

            <dependency>
                <groupId>javax.persistence</groupId>
                <artifactId>persistence-api</artifactId>
                <version>${persistence.api.version}</version>
            </dependency>

            <dependency>
                <groupId>com.github.pagehelper</groupId>
                <artifactId>pagehelper-spring-boot-starter</artifactId>
                <version>${pagehelper.spring.boot.starter.version}</version>
                <exclusions>
                    <exclusion>
                        <groupId>org.mybatis.spring.boot</groupId>
                        <artifactId>mybatis-spring-boot-starter</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>

            <dependency>
                <groupId>org.apache.httpcomponents</groupId>
                <artifactId>httpclient</artifactId>
                <version>${apache.httpclient.version}</version>
            </dependency>

            <dependency>
                <groupId>io.springfox</groupId>
                <artifactId>springfox-swagger2</artifactId>
                <version>${swagger2.version}</version>
                <exclusions>
                    <exclusion>
                        <groupId>io.swagger</groupId>
                        <artifactId>swagger-annotations</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>io.swagger</groupId>
                        <artifactId>swagger-models</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>

            <dependency>
                <groupId>io.swagger</groupId>
                <artifactId>swagger-models</artifactId>
                <version>${swagger2.ext.version}</version>
            </dependency>

            <dependency>
                <groupId>io.swagger</groupId>
                <artifactId>swagger-annotations</artifactId>
                <version>${swagger2.ext.version}</version>
            </dependency>

            <dependency>
                <groupId>com.github.xiaoymin</groupId>
                <artifactId>swagger-bootstrap-ui</artifactId>
                <version>${swagger.ui.version}</version>
            </dependency>

            <dependency>
                <groupId>com.google.guava</groupId>
                <artifactId>guava</artifactId>
                <version>${guava.version}</version>
            </dependency>

            <dependency>
                <groupId>cn.hutool</groupId>
                <artifactId>hutool-all</artifactId>
                <version>${hutool.version}</version>
            </dependency>

            <dependency>
                <groupId>com.google.zxing</groupId>
                <artifactId>core</artifactId>
                <version>${zxing.version}</version>
            </dependency>

            <!--生态包配置定位-->
            <dependency>
                <groupId>com.sinszm</groupId>
                <artifactId>szm-boot-common</artifactId>
                <version>${szm.boot.common.version}</version>
            </dependency>

            <dependency>
                <groupId>com.sinszm</groupId>
                <artifactId>szm-boot-mdb</artifactId>
                <version>${szm.boot.mdb.version}</version>
            </dependency>

            <dependency>
                <groupId>com.sinszm</groupId>
                <artifactId>szm-boot-web</artifactId>
                <version>${szm.boot.web.version}</version>
            </dependency>

            <dependency>
                <groupId>com.sinszm</groupId>
                <artifactId>szm-boot-basicwx</artifactId>
                <version>${szm.boot.basicwx.version}</version>
            </dependency>

            <dependency>
                <groupId>com.sinszm</groupId>
                <artifactId>szm-boot-es</artifactId>
                <version>${szm.boot.es.version}</version>
            </dependency>

            <dependency>
                <groupId>org.apache.cxf</groupId>
                <artifactId>cxf-spring-boot-starter-jaxws</artifactId>
                <version>${cxf.version}</version>
            </dependency>

            <dependency>
                <groupId>com.qcloud</groupId>
                <artifactId>cos_api</artifactId>
                <version>${cos.version}</version>
            </dependency>

            <!-- ES -->
            <dependency>
                <groupId>org.elasticsearch</groupId>
                <artifactId>elasticsearch</artifactId>
                <version>${es.version}</version>
            </dependency>

            <dependency>
                <groupId>org.elasticsearch.client</groupId>
                <artifactId>elasticsearch-rest-high-level-client</artifactId>
                <version>${es.version}</version>
            </dependency>

            <dependency>
                <groupId>org.elasticsearch.client</groupId>
                <artifactId>elasticsearch-rest-client</artifactId>
                <version>${es.version}</version>
            </dependency>
            <!-- ES -->

            <dependency>
                <groupId>com.auth0</groupId>
                <artifactId>java-jwt</artifactId>
                <version>${jwt.version}</version>
            </dependency>

        </dependencies>
    </dependencyManagement>

    <!--配置编译插件-->
    <profiles>
        <profile>
            <id>release</id>
            <activation>
                <activeByDefault>true</activeByDefault>
            </activation>
            <properties>
                <gpg.executable>gpg</gpg.executable>
            </properties>
            <build>
                <finalName>${project.name}</finalName>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-compiler-plugin</artifactId>
                        <version>3.3</version>
                        <configuration>
                            <source>1.8</source>
                            <target>1.8</target>
                            <compilerArgs>
                                <arg>-parameters</arg>
                                <compilerArg>-Xlint:unchecked</compilerArg>
                            </compilerArgs>
                            <useIncrementalCompilation>false</useIncrementalCompilation>
                        </configuration>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-source-plugin</artifactId>
                        <version>3.0.1</version>
                        <executions>
                            <execution>
                                <phase>package</phase>
                                <goals>
                                    <goal>jar-no-fork</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-javadoc-plugin</artifactId>
                        <version>3.2.0</version>
                        <executions>
                            <execution>
                                <phase>package</phase>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                                <configuration>
                                    <charset>${charset}</charset>
                                    <encoding>${charset}</encoding>
                                    <docencoding>${charset}</docencoding>
                                    <doclint>none</doclint>
                                </configuration>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-jar-plugin</artifactId>
                        <version>3.0.2</version>
                        <configuration>
                            <archive>
                                <manifest>
                                    <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
                                </manifest>
                            </archive>
                        </configuration>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <version>1.6</version>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-deploy-plugin</artifactId>
                        <version>2.8.2</version>
                        <configuration>
                            <updateReleaseInfo>true</updateReleaseInfo>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
            <distributionManagement>
                <repository>
                    <id>sonatype-nexus-releases</id>
                    <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
                </repository>
                <snapshotRepository>
                    <id>sonatype-nexus-snapshots</id>
                    <url>https://oss.sonatype.org/content/repositories/snapshots/</url>
                </snapshotRepository>
            </distributionManagement>
        </profile>
    </profiles>

</project>
