<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.4paradigm.hybridse</groupId>
    <artifactId>hybridse-java</artifactId>
    <version>0.3.0</version>
    <modules>
        <module>hybridse-sdk</module>
        <module>hybridse-native</module>
        <module>hybridse-proto</module>
    </modules>
    <packaging>pom</packaging>
    <name>hybridse</name>
    <description>The LLVM-based, hybrid-execution and high-performance SQL engine.</description>
    <url>https://github.com/4paradigm/HybridSE</url>
    <licenses>
        <license>
            <name>The Apache Software License, Version 2.0</name>
            <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
            <distribution>repo</distribution>
        </license>
    </licenses>
    <developers>
        <developer>
            <id>jingchen2222</id>
            <name>Chen22</name>
            <email>chenjing@4paradigm.com</email>
            <url>https://github.com/jingchen2222</url>
            <organization>4Paradigm</organization>
            <organizationUrl>https://www.4paradigm.com/</organizationUrl>
        </developer>
    </developers>
    <scm>
        <connection>scm:git@github.com:4paradigm/OpenMLDB.git</connection>
        <developerConnection>scm:git:ssh://git@github.com:4paradigm/OpenMLDB.git</developerConnection>
        <tag>HEAD</tag>
        <url>https://github.com/4paradigm/OpenMLDB</url>
    </scm>
    <properties>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <plugin.violationSeverity>error</plugin.violationSeverity>
        <spotless-maven-plugin.version>2.9.0</spotless-maven-plugin.version>
        <eclipse.jdt.version>4.13.0</eclipse.jdt.version>
        <project.version.base>0.3.0</project.version.base>
        <project.version.suffix></project.version.suffix>
    </properties>
    <build>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>versions-maven-plugin</artifactId>
                    <version>2.8.1</version>
                    <configuration>
                        <generateBackupPoms>false</generateBackupPoms>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-compiler-plugin</artifactId>
                    <version>3.7.0</version>
                    <configuration>
                        <source>1.8</source>
                        <target>1.8</target>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-surefire-plugin</artifactId>
                    <version>2.20.1</version>
                    <configuration>
                        <reuseForks>false</reuseForks>
                        <forkCount>1</forkCount>
                        <argLine>@{argLine} -Xmx4G</argLine>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.jacoco</groupId>
                    <artifactId>jacoco-maven-plugin</artifactId>
                    <version>0.8.7</version>
                    <executions>
                        <execution>
                            <goals>
                                <goal>prepare-agent</goal>
                            </goals>
                        </execution>
                        <execution>
                            <id>report</id>
                            <phase>prepare-package</phase>
                            <goals>
                                <goal>report</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-site-plugin</artifactId>
                    <version>3.9.1</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-checkstyle-plugin</artifactId>
                    <version>3.1.2</version>
                    <configuration>
                        <configLocation>style_checks.xml</configLocation>
                        <consoleOutput>false</consoleOutput>
                        <failsOnError>true</failsOnError>
                        <failOnViolation>true</failOnViolation>
                        <violationSeverity>${plugin.violationSeverity}</violationSeverity>
                    </configuration>
                    <dependencies>
                        <dependency>
                            <groupId>com.puppycrawl.tools</groupId>
                            <artifactId>checkstyle</artifactId>
                            <version>8.41</version>
                        </dependency>
                    </dependencies>
                </plugin>
                <plugin>
                    <groupId>com.diffplug.spotless</groupId>
                    <artifactId>spotless-maven-plugin</artifactId>
                    <version>${spotless-maven-plugin.version}</version>
                    <!-- spotless:check is bound to verfiy phase by default -->
                    <configuration>
                        <java>
                            <eclipse>
                                <version>${eclipse.jdt.version}</version>
                                <file>eclipse-formatter.xml</file> <!-- optional -->
                            </eclipse>
                            <!-- <licenseHeader> <!&#45;&#45; specify either content or file, but not both &#45;&#45;> -->
                            <!--     <content>/* Copyright $YEAR 4Paradigm */</content>  <!&#45;&#45; or <file>${basedir}/license&#45;header</file> &#45;&#45;> -->
                            <!--     <delimiter> -->
                            <!--         Licensed -->
                            <!--     </delimiter>  <!&#45;&#45; content until first occurrence of the delimiter regex will be interpreted as header section &#45;&#45;> -->
                            <!-- </licenseHeader> -->
                        </java>
                    </configuration>
                </plugin>
                <!-- For deploying in central repository -->
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-gpg-plugin</artifactId>
                    <version>3.0.1</version>
                    <executions>
                        <execution>
                            <id>sign-artifacts</id>
                            <phase>verify</phase>
                            <goals>
                                <goal>sign</goal>
                            </goals>
                            <configuration>
                                <!-- <useAgent>true</useAgent> -->
                                <!-- uncomment this if want to specify gpg sign key -->
                                <!-- <keyname>${gpg.keyname}</keyname> -->

                                <passphraseServerId>gpg.passphrase</passphraseServerId>

                                <!-- <passphrase>${gpg.passphrase}</passphrase> -->
                            </configuration>
                        </execution>
                    </executions>
                </plugin>
                <plugin>
                    <groupId>org.sonatype.plugins</groupId>
                    <artifactId>nexus-staging-maven-plugin</artifactId>
                    <version>1.6.7</version>
                    <extensions>true</extensions>
                    <configuration>
                        <serverId>ossrh</serverId>
                        <nexusUrl>https://s01.oss.sonatype.org/</nexusUrl>
                        <autoReleaseAfterClose>true</autoReleaseAfterClose>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-release-plugin</artifactId>
                    <version>2.4.2</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-source-plugin</artifactId>
                    <version>2.2.1</version>
                    <executions>
                        <execution>
                            <id>attach-sources</id>
                            <goals>
                                <goal>jar-no-fork</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-javadoc-plugin</artifactId>
                    <version>2.9.1</version>
                    <executions>
                        <execution>
                            <id>attach-javadocs</id>
                            <goals>
                                <goal>jar</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin>
            </plugins>
        </pluginManagement>

        <plugins>
            <plugin>
                <groupId>org.sonatype.plugins</groupId>
                <artifactId>nexus-staging-maven-plugin</artifactId>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-gpg-plugin</artifactId>
            </plugin>
            <plugin>
                <groupId>org.jacoco</groupId>
                <artifactId>jacoco-maven-plugin</artifactId>
            </plugin>
        </plugins>
    </build>
    <!--
    <distributionManagement>
        <snapshotRepository>
            <id>github</id>
            <name>4paradigm</name>
            <url>https://maven.pkg.github.com/4paradigm/NativeSpark/Snapshot</url>
        </snapshotRepository>
        <repository>
            <id>github</id>
            <name>4paradigm</name>
            <url>https://maven.pkg.github.com/4paradigm/NativeSpark/Release</url>
        </repository>
    </distributionManagement>
    -->
    <distributionManagement>
        <snapshotRepository>
            <id>ossrh</id>
            <url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
        </snapshotRepository>
        <repository>
            <id>ossrh</id>
            <url>https://s01.oss.sonatype.org/service/local/staging/deploy/maven2/</url>
        </repository>
    </distributionManagement>
    <reporting>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-checkstyle-plugin</artifactId>
                <version>3.1.2</version>
                <reportSets>
                    <reportSet>
                        <reports>
                            <report>checkstyle</report>
                        </reports>
                    </reportSet>
                </reportSets>
                <configuration>
                    <configLocation>style_checks.xml</configLocation>
                </configuration>
            </plugin>
            <plugin>
                <groupId>com.github.spotbugs</groupId>
                <artifactId>spotbugs-maven-plugin</artifactId>
                <version>4.2.2</version>
            </plugin>
        </plugins>
    </reporting>
</project>
