<?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>

    <name>Tarantool Java driver</name>
    <description>Driver for Tarantool 1.10+ based on Netty framework</description>
    <url>https://tarantool.io</url>

    <groupId>io.tarantool</groupId>
    <artifactId>driver</artifactId>
    <packaging>jar</packaging>
    <version>0.1.1</version>

    <licenses>
        <license>
            <name>The BSD License</name>
            <url>https://opensource.org/licenses/BSD-3-Clause</url>
        </license>
    </licenses>

    <organization>
        <name>Tarantool</name>
        <url>https://tarantool.io/</url>
    </organization>

    <developers>
        <developer>
            <id>akudiyar</id>
            <name>Alexey Kuzin</name>
            <email>akudiyar@gmail.com</email>
            <organization>Tarantool</organization>
            <organizationUrl>https://tarantool.io/</organizationUrl>
        </developer>
    </developers>

    <issueManagement>
        <system>GitHub</system>
        <url>https://github.com/akudiyar/tarantool-java-driver/issues/</url>
    </issueManagement>

    <scm>
        <connection>scm:git:git@github.com:akudiyar/tarantool-java-driver.git</connection>
        <developerConnection>scm:git:git@github.com:akudiyar/tarantool-java-driver.git</developerConnection>
        <url>https://github.com/akudiyar/tarantool-java-driver/tree/master</url>
      <tag>v0.1.1</tag>
  </scm>

    <properties>
        <checkstyle.config>${project.basedir}/src/test/resources/io/tarantool/driver/checkstyle.xml</checkstyle.config>
        <checkstyle.suppressions>${project.basedir}/src/test/resources/io/tarantool/driver/suppressions.xml</checkstyle.suppressions>
        <logging.config>${project.basedir}/src/test/resources/logback-test.xml</logging.config>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
        <logging.logLevel>debug</logging.logLevel>
    </properties>

    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>3.8.0</version>
                <configuration>
                    <compilerVersion>1.8</compilerVersion>
                    <fork>true</fork>
                    <debug>true</debug>
                    <optimize>true</optimize>
                    <showDeprecation>true</showDeprecation>
                    <showWarnings>true</showWarnings>
                    <source>8</source>
                    <target>8</target>
                    <excludes>
                        <exclude>**/package-info.java</exclude>
                    </excludes>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-enforcer-plugin</artifactId>
                <version>3.0.0-M3</version>
                <executions>
                    <execution>
                        <id>enforce-tools</id>
                        <goals>
                            <goal>enforce</goal>
                        </goals>
                        <configuration>
                            <rules>
                                <requireJavaVersion>
                                    <!-- Enforce JDK 1.8+ for compilation. -->
                                    <version>[1.8.0,)</version>
                                </requireJavaVersion>
                                <requireMavenVersion>
                                    <version>[3.1.1,)</version>
                                </requireMavenVersion>
                            </rules>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-checkstyle-plugin</artifactId>
                <version>3.1.1</version>
                <executions>
                    <execution>
                        <id>check-style</id>
                        <goals>
                            <goal>check</goal>
                        </goals>
                        <phase>validate</phase>
                        <configuration>
                            <consoleOutput>true</consoleOutput>
                            <logViolationsToConsole>true</logViolationsToConsole>
                            <!--<failsOnError>false</failsOnError>-->
                            <failOnViolation>false</failOnViolation>
                            <configLocation>${checkstyle.config}</configLocation>
                            <suppressionsLocation>${checkstyle.suppressions}</suppressionsLocation>
                            <propertyExpansion>project.basedir=${project.basedir}</propertyExpansion>
                            <sourceDirectories>
                                <sourceDirectory>${project.build.sourceDirectory}</sourceDirectory>
                                <sourceDirectory>${project.build.testSourceDirectory}</sourceDirectory>
                            </sourceDirectories>
                        </configuration>
                    </execution>
                </executions>
                <dependencies>
                    <dependency>
                        <groupId>com.puppycrawl.tools</groupId>
                        <artifactId>checkstyle</artifactId>
                        <version>8.31</version>
                    </dependency>
                </dependencies>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-surefire-plugin</artifactId>
                <version>3.0.0-M4</version>
                <configuration>
                    <includes>
                        <include>**/*Test.java</include>
                    </includes>
                    <systemPropertyVariables>
                        <logback.configurationFile>${logging.config}</logback.configurationFile>
                        <logLevel>${logging.logLevel}</logLevel>
                    </systemPropertyVariables>
                    <trimStackTrace>false</trimStackTrace>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-javadoc-plugin</artifactId>
                <version>3.2.0</version>
                <configuration>
                    <detectOfflineLinks>false</detectOfflineLinks>
                    <breakiterator>true</breakiterator>
                    <version>false</version>
                    <author>false</author>
                    <keywords>true</keywords>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.sonatype.plugins</groupId>
                <artifactId>nexus-staging-maven-plugin</artifactId>
                <version>1.6.8</version>
                <extensions>true</extensions>
                <configuration>
                    <serverId>ossrh</serverId>
                    <nexusUrl>https://oss.sonatype.org/</nexusUrl>
                    <autoReleaseAfterClose>false</autoReleaseAfterClose>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-release-plugin</artifactId>
                <version>3.0.0-M1</version>
                <configuration>
                    <autoVersionSubmodules>true</autoVersionSubmodules>
                    <releaseProfiles>release</releaseProfiles>
                    <goals>deploy</goals>
                </configuration>
            </plugin>
        </plugins>
    </build>

    <dependencies>
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-core</artifactId>
            <version>5.2.6.RELEASE</version>
        </dependency>
        <dependency>
            <groupId>io.netty</groupId>
            <artifactId>netty-all</artifactId>
            <version>4.1.50.Final</version>
        </dependency>
        <dependency>
            <groupId>org.msgpack</groupId>
            <artifactId>msgpack-core</artifactId>
            <version>0.8.20</version>
        </dependency>
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-api</artifactId>
            <version>1.7.30</version>
        </dependency>
        <dependency>
            <groupId>ch.qos.logback</groupId>
            <artifactId>logback-core</artifactId>
            <version>1.2.3</version>
        </dependency>
        <dependency>
            <groupId>com.fasterxml.jackson.core</groupId>
            <artifactId>jackson-databind</artifactId>
            <version>2.11.2</version>
        </dependency>
        <!-- Test dependencies -->
        <dependency>
            <groupId>org.junit.jupiter</groupId>
            <artifactId>junit-jupiter</artifactId>
            <version>5.6.2</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>ch.qos.logback</groupId>
            <artifactId>logback-classic</artifactId>
            <version>1.2.3</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.testcontainers</groupId>
            <artifactId>testcontainers</artifactId>
            <version>1.15.0-rc2</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>org.testcontainers</groupId>
            <artifactId>junit-jupiter</artifactId>
            <version>1.14.3</version>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>com.google.code.findbugs</groupId>
            <artifactId>jsr305</artifactId>
            <version>3.0.2</version>
        </dependency>
    </dependencies>

    <profiles>
        <profile>
            <id>integration</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-antrun-plugin</artifactId>
                        <version>3.0.0</version>
                        <executions>
                            <execution>
                                <id>process-test-classes</id>
                                <phase>process-test-classes</phase>
                                <goals>
                                    <goal>run</goal>
                                </goals>
                                <configuration>
                                    <target>
                                        <chmod file="${project.build.testOutputDirectory}/org/testcontainers/containers/server.lua" perm="777" />
                                    </target>
                                </configuration>
                            </execution>
                        </executions>
                    </plugin>
                    <plugin>
                        <artifactId>maven-surefire-plugin</artifactId>
                        <version>3.0.0-M4</version>
                        <configuration>
                            <includes>
                                <include>**/*IT.java</include>
                            </includes>
                            <systemPropertyVariables>
                                <logback.configurationFile>${logging.config}</logback.configurationFile>
                                <logLevel>${logging.logLevel}</logLevel>
                            </systemPropertyVariables>
                            <trimStackTrace>false</trimStackTrace>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>
        <profile>
            <id>release</id>
            <build>
                <plugins>
                    <plugin>
                        <artifactId>maven-source-plugin</artifactId>
                        <version>3.2.0</version>
                        <configuration>
                            <archive>
                                <manifestEntries>
                                    <Bundle-ManifestVersion>2</Bundle-ManifestVersion>
                                    <Bundle-Name>${project.name}</Bundle-Name>
                                    <Bundle-SymbolicName>${project.groupId}.${project.artifactId}.source</Bundle-SymbolicName>
                                    <Bundle-Vendor>${project.organization.name}</Bundle-Vendor>
                                </manifestEntries>
                            </archive>
                        </configuration>
                        <executions>
                            <execution>
                                <id>attach-sources</id>
                                <phase>prepare-package</phase>
                                <goals>
                                    <goal>jar-no-fork</goal>
                                </goals>
                            </execution>
                            <execution>
                                <id>attach-test-sources</id>
                                <phase>prepare-package</phase>
                                <goals>
                                    <goal>test-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>
                                <id>attach-javadocs</id>
                                <goals>
                                    <goal>jar</goal>
                                </goals>
                            </execution>
                        </executions>
                    </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>
                                <configuration>
                                    <gpgArguments>
                                        <arg>--pinentry-mode</arg>
                                        <arg>loopback</arg>
                                    </gpgArguments>
                                </configuration>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

    <distributionManagement>
        <snapshotRepository>
            <id>sonatype-nexus-snapshots</id>
            <url>https://oss.sonatype.org/content/repositories/snapshots</url>
        </snapshotRepository>
        <repository>
            <id>sonatype-nexus-staging</id>
            <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
        </repository>
    </distributionManagement>
</project>