<?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>technology.dice.open</groupId>
  <artifactId>dice-where</artifactId>
  <version>1.0.3</version>
  <name>dice-where</name>

  <description>dice-where is a low memory footprint, highly efficient
    Geo IP lookup library that relies on locally available data. </description>
  <url>http://open.dice.technology/dice-where</url>

  <scm>
    <connection>scm:git:git@github.com:DiceTechnology/dice-where.git</connection>
    <developerConnection>scm:git:ssh://github.com:DiceTechnology/dice-where.git</developerConnection>
    <url>http://github.com/DiceTechnology/dice-where/tree/master</url>
  </scm>

  <licenses>
    <license>
      <name>TODO License name</name>
      <url>TODO License URL</url>
    </license>
  </licenses>

  <distributionManagement>
    <repository>
      <id>bintray-dicetechnology-dice-where</id>
      <name>dicetechnology-dice-where</name>
      <url>https://api.bintray.com/maven/dicetechnology/dice-where/dice-where/;publish=1</url>
    </repository>
  </distributionManagement>

  <developers>
    <developer>
      <name>Alex Kryvenkyi</name>
      <id>zorg</id>
      <email>akryvenkyi at endeavorco dot com</email>
      <organization>DiceTechnology</organization>
      <organizationUrl>http://open.dice.technology</organizationUrl>
    </developer>
    <developer>
      <name>Goncalo Luiz</name>
      <id>gedl</id>
      <email>gluiz at endeavorco dot com</email>
      <organization>DiceTechnology</organization>
      <organizationUrl>http://open.dice.technology</organizationUrl>
    </developer>
    <developer>
      <name>Julian Howarth</name>
      <id>julianhowarth</id>
      <email>jhowarth at endeavorco dot com</email>
      <organization>DiceTechnology</organization>
      <organizationUrl>http://open.dice.technology</organizationUrl>
    </developer>
    <developer>
      <name>Savvas Michael</name>
      <id>SavvasMichael</id>
      <email>smichael at endeavorco dot com</email>
      <organization>DiceTechnology</organization>
      <organizationUrl>http://open.dice.technology</organizationUrl>
    </developer>
    <developer>
      <name>Stanislav Vasilev</name>
      <id>stykiaz</id>
      <email>svasilev at endeavorco dot com</email>
      <organization>DiceTechnology</organization>
      <organizationUrl>http://open.dice.technology</organizationUrl>
    </developer>
    <developer>
      <name>Kamil Wlodarczyk</name>
      <id>fifol-img</id>
      <email>kwlodarczyk at endeavorco dot com</email>
      <organization>DiceTechnology</organization>
      <organizationUrl>http://open.dice.technology</organizationUrl>
    </developer>
  </developers>

  <properties>
    <guava.version>21.0</guava.version>
    <ipaddress.version>4.2.0</ipaddress.version>
    <mapdb.version>3.0.7</mapdb.version>
    <protobuf.version>3.6.0</protobuf.version>
    <junit.version>4.12</junit.version>
    <mockito.version>2.7.22</mockito.version>
    <jococo.version>0.8.1</jococo.version>
    <jmh.version>1.21</jmh.version>
  </properties>

  <build>
    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
        <version>3.6.0</version>
        <configuration>
          <source>1.8</source>
          <target>1.8</target>
        </configuration>
      </plugin>
      <plugin>
        <groupId>com.github.os72</groupId>
        <artifactId>protoc-jar-maven-plugin</artifactId>
        <version>3.6.0.1</version>
        <executions>
          <execution>
            <phase>generate-sources</phase>
            <goals>
              <goal>run</goal>
            </goals>
            <configuration>
              <addProtoSources>all</addProtoSources>
              <includeMavenTypes>direct</includeMavenTypes>
              <inputDirectories>
                <include>src/main/protobuf</include>
              </inputDirectories>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.jacoco</groupId>
        <artifactId>jacoco-maven-plugin</artifactId>
        <version>${jococo.version}</version>
        <configuration>
          <excludes>
            <exclude>**technology/dice/dicewhere/lineprocessing/serializers/protobuf/*</exclude>
          </excludes>
        </configuration>
        <executions>
          <execution>
            <id>default-prepare-agent</id>
            <goals>
              <goal>prepare-agent</goal>
            </goals>
          </execution>
          <execution>
            <id>default-report</id>
            <phase>prepare-package</phase>
            <goals>
              <goal>report</goal>
            </goals>
          </execution>
          <execution>
            <id>check</id>
            <phase>test</phase>
            <goals>
              <goal>check</goal>
            </goals>
            <configuration>
              <rules>
                <rule implementation="org.jacoco.maven.RuleConfiguration">
                  <element>BUNDLE</element>
                  <limits>
                    <limit implementation="org.jacoco.report.check.Limit">
                      <counter>COMPLEXITY</counter>
                      <value>COVEREDRATIO</value>
                      <minimum>0.6</minimum>
                    </limit>
                  </limits>
                </rule>
              </rules>
            </configuration>
          </execution>
        </executions>
      </plugin>
    </plugins>
    <extensions>
      <extension>
        <groupId>org.springframework.build</groupId>
        <artifactId>aws-maven</artifactId>
        <version>5.0.0.RELEASE</version>
      </extension>
    </extensions>
  </build>

  <profiles>
    <profile>
      <id>build-extras</id>
      <activation>
        <activeByDefault>true</activeByDefault>
      </activation>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-source-plugin</artifactId>
            <version>2.4</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.10.3</version>
            <configuration>
              <sourceFileExcludes>
                <sourceFileExclude>**/protobuf/*.java</sourceFileExclude>
              </sourceFileExcludes>
            </configuration>
            <executions>
              <execution>
                <id>attach-javadocs</id>
                <goals>
                  <goal>jar</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
    <profile>
      <id>bintray</id>
      <repositories>
        <repository>
          <snapshots>
            <enabled>false</enabled>
          </snapshots>
          <id>bintray-dicetechnology-dice-where</id>
          <name>bintray</name>
          <url>https://dl.bintray.com/dicetechnology/dice-where</url>
        </repository>
      </repositories>
      <pluginRepositories>
        <pluginRepository>
          <snapshots>
            <enabled>false</enabled>
          </snapshots>
          <id>bintray-dicetechnology-dice-where</id>
          <name>bintray-plugins</name>
          <url>https://dl.bintray.com/dicetechnology/dice-where</url>
        </pluginRepository>
      </pluginRepositories>
      <build>
        <plugins>
          <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>
        </plugins>
      </build>
    </profile>
  </profiles>

  <reporting>
    <plugins>
      <plugin>
        <groupId>org.jacoco</groupId>
        <artifactId>jacoco-maven-plugin</artifactId>
        <reportSets>
          <reportSet>
            <reports>
              <report>report</report>
            </reports>
          </reportSet>
        </reportSets>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-javadoc-plugin</artifactId>
        <version>2.10.4</version>
      </plugin>
    </plugins>
  </reporting>

  <dependencies>
    <dependency>
      <groupId>com.github.seancfoley</groupId>
      <artifactId>ipaddress</artifactId>
      <version>${ipaddress.version}</version>
    </dependency>
    <dependency>
      <groupId>org.mapdb</groupId>
      <artifactId>mapdb</artifactId>
      <version>${mapdb.version}</version>
    </dependency>
    <dependency>
      <groupId>com.google.protobuf</groupId>
      <artifactId>protobuf-java</artifactId>
      <version>${protobuf.version}</version>
    </dependency>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>${junit.version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.mockito</groupId>
      <artifactId>mockito-core</artifactId>
      <version>${mockito.version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.openjdk.jmh</groupId>
      <artifactId>jmh-generator-annprocess</artifactId>
      <version>${jmh.version}</version>
      <scope>test</scope>
    </dependency>
  </dependencies>

</project>
