<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>
        <groupId>uk.ac.ebi.ddi.maven</groupId>
        <artifactId>ddi-base-master</artifactId>
        <version>1.2</version>
    </parent>

    <groupId>uk.ac.ebi.ddi</groupId>
    <artifactId>ddi-ebi-logs</artifactId>
    <version>1.0</version>
    <packaging>jar</packaging>

    <scm>
        <connection>scm:git:github.com/OmicsDI/ebi-logs-reader.git</connection>
        <developerConnection>scm:git:git@github.com:OmicsDI/ebi-logs-reader.git</developerConnection>
        <url>https://github.com/OmicsDI/ebi-logs-reader.git</url>
        <tag>ddi-ebi-logs-1.0</tag>
    </scm>

    <properties>
        <org.cloudfoundry-version>0.8.0</org.cloudfoundry-version>
        <ehcache-core.version>2.5.1</ehcache-core.version>
        <aspectjrt.version>1.6.10</aspectjrt.version>
        <standard.version>1.1.2</standard.version>
        <maven.checkstyle.version>2.17</maven.checkstyle.version>
        <checkstyle.config.location>checkstyle.xml</checkstyle.config.location>
    </properties>

    <dependencies>
        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-api</artifactId>
            <version>1.8.0-beta2</version>
        </dependency>
        <dependency>
            <groupId>org.springframework.retry</groupId>
            <artifactId>spring-retry</artifactId>
            <version>1.1.0.RELEASE</version>
        </dependency>
        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <scope>test</scope>
        </dependency>
        <dependency>
            <groupId>commons-cli</groupId>
            <artifactId>commons-cli</artifactId>
        </dependency>
        <dependency>
            <groupId>org.json</groupId>
            <artifactId>json</artifactId>
        </dependency>
        <dependency>
            <groupId>org.apache.httpcomponents</groupId>
            <artifactId>httpclient</artifactId>
        </dependency>
        <dependency>
            <groupId>com.google.code.gson</groupId>
            <artifactId>gson</artifactId>
        </dependency>
        <dependency>
            <groupId>com.fasterxml.jackson.core</groupId>
            <artifactId>jackson-databind</artifactId>
            <version>2.9.7</version>
        </dependency>
        <dependency>
            <groupId>com.fasterxml.jackson.core</groupId>
            <artifactId>jackson-core</artifactId>
            <version>2.9.7</version>
        </dependency>
        <dependency>
            <groupId>com.fasterxml.jackson.core</groupId>
            <artifactId>jackson-annotations</artifactId>
            <version>2.9.7</version>
        </dependency>

        <!-- Spring test -->
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-test</artifactId>
            <scope>test</scope>
        </dependency>
        <!-- Spring Core -->
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-core</artifactId>
            <type>jar</type>
        </dependency>
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-tx</artifactId>
            <type>jar</type>
        </dependency>
        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-webmvc</artifactId>
            <type>jar</type>
        </dependency>

        <!-- https://mvnrepository.com/artifact/com.google.guava/guava -->
        <dependency>
            <groupId>com.google.guava</groupId>
            <artifactId>guava</artifactId>
            <version>19.0</version>
        </dependency>


        <!-- Log System -->
        <dependency>
            <groupId>log4j</groupId>
            <artifactId>log4j</artifactId>
            <version>${log4j.version}</version>
        </dependency>

        <!--
        Ver 6.4.0 of
        elasticsearch-rest-high-level-client-6.4.0.jar in
        https://mvnrepository.com/artifact/org.elasticsearch.client/elasticsearch-rest-high-level-client
        is missing RestHighLevelClient.class
        (c.f. https://github.com/elastic/elasticsearch/pull/32731)
        I had to download it manually from
        https://jar-download.com/?search_box=elasticsearch-rest-high-level-client - into ~/.m2/repository/org/elasticsearch/client/elasticsearch-rest-high-level-client/6.4.0/)
       -->
        <dependency>
            <groupId>org.elasticsearch.client</groupId>
            <artifactId>elasticsearch-rest-high-level-client</artifactId>
            <version>6.4.0</version>
            <!--
            TODO: Uncomment when https://mvnrepository.com/artifact/org.elasticsearch.client/elasticsearch-rest-high-level-client
                        has been fixed - c.f. above <type>pom</type>
           -->
        </dependency>
    </dependencies>
    <build>
        <finalName>ddi-ebi-logs</finalName>
        <plugins>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-release-plugin</artifactId>
                <version>2.5.3</version>
                <configuration>
                    <localCheckout>true</localCheckout>
                    <pushChanges>false</pushChanges>
                    <mavenExecutorId>forked-path</mavenExecutorId>
                    <arguments>-Dgpg.passphrase=${gpg.phrase}</arguments>
                    <checkModificationExcludes>
                        <checkModificationExclude>pom.xml</checkModificationExclude>
                    </checkModificationExcludes>
                </configuration>
                <dependencies>
                    <dependency>
                        <groupId>org.apache.maven.scm</groupId>
                        <artifactId>maven-scm-provider-gitexe</artifactId>
                        <version>1.9.5</version>
                    </dependency>
                </dependencies>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>3.8.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.7.2</version>
                <configuration>
                    <excludes>
                        <exclude>**/services/*.java</exclude>
                        <exclude>uk.ac.ebi.ddi.annotation.IntersectionTest</exclude>
                    </excludes>
                    <skipTests>true</skipTests>
                    <junitArtifactName>junit:junit</junitArtifactName>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-checkstyle-plugin</artifactId>
                <version>${maven.checkstyle.version}</version>
                <executions>
                    <execution>
                        <id>checkstyle</id>
                        <phase>validate</phase>
                        <goals>
                            <goal>check</goal>
                        </goals>
                        <configuration>
                            <failOnViolation>true</failOnViolation>
                            <consoleOutput>true</consoleOutput>
                        </configuration>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>
    <repositories>
        <repository>
            <id>nexus-ebi-release-repo</id>
            <url>
                http://www.ebi.ac.uk/Tools/maven/repos/content/groups/ebi-repo/
            </url>
        </repository>
    </repositories>

</project>