<?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/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <groupId>com.nhl.link.rest</groupId>
    <artifactId>link-rest-parent</artifactId>
    <version>2.9</version>

    <name>link-rest: Parent POM of LR modules</name>
    <description>Parent POM of LR modules</description>
    <packaging>pom</packaging>

    <modules>
        <module>link-rest-annotations</module>
        <module>link-rest</module>
        <module>link-rest-client</module>
        <module>link-rest-bom</module>
        <module>link-rest-docs</module>
    </modules>

    <properties>

        <!-- standard Maven properties -->
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
        <maven.compiler.source>1.8</maven.compiler.source>
        <maven.compiler.target>1.8</maven.compiler.target>

        <!-- Custom properties (mostly framework versions) -->
        <servlet-api-version>3.0.0.v201112011016</servlet-api-version>
        <slf4j-version>1.7.12</slf4j-version>
        <cayenne-version>4.0.B1</cayenne-version>
        <jersey-version>2.22.1</jersey-version>
        <jackson-version>2.6.3</jackson-version>
    </properties>

    <url>https://github.com/nhl/link-rest</url>

    <licenses>
        <license>
            <name>Apache 2.0 License</name>
            <url>https://github.com/nhl/link-rest/blob/master/LICENSE.txt</url>
            <distribution>repo</distribution>
        </license>
    </licenses>


    <developers>
        <developer>
            <id>andrus</id>
            <name>Andrus Adamchik</name>
            <email>andrus@objectstyle.com</email>
            <organization>ObjectStyle</organization>
            <timezone>America/New_York</timezone>
        </developer>
    </developers>

    <scm>
        <connection>scm:git:https://github.com/nhl/link-rest</connection>
        <developerConnection>scm:git:ssh://git@github.com/nhl/link-rest</developerConnection>
        <url>https://github.com/nhl/link-rest</url>
        <tag>link-rest-parent-2.9</tag>
    </scm>

    <distributionManagement>
        <repository>
            <uniqueVersion>false</uniqueVersion>
            <id>oss-sonatype-releases</id>
            <name>Deployment Repository</name>
            <url>https://oss.sonatype.org/service/local/staging/deploy/maven2</url>
        </repository>
        <snapshotRepository>
            <id>linkrest-snapshots</id>
            <url>http://maven.objectstyle.org/nexus/content/repositories/linkrest-snapshots</url>
        </snapshotRepository>
    </distributionManagement>

    <repositories>
        <repository>
            <id>linkrest-dependencies</id>
            <name>Link Rest Dependencies Repo</name>
            <url>http://maven.objectstyle.org/nexus/content/groups/linkrest</url>
        </repository>
    </repositories>
    <pluginRepositories>
        <pluginRepository>
            <id>linkrest-dependencies</id>
            <name>Link Rest Dependencies Repo</name>
            <url>http://maven.objectstyle.org/nexus/content/groups/linkrest</url>
            <snapshots>
                <enabled>false</enabled>
            </snapshots>
        </pluginRepository>
    </pluginRepositories>

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>junit</groupId>
                <artifactId>junit</artifactId>
                <version>4.12</version>
            </dependency>
            <dependency>
                <groupId>org.mockito</groupId>
                <artifactId>mockito-all</artifactId>
                <version>1.9.5-rc1</version>
            </dependency>

            <!-- Let's only use the servlet spec used by Jetty. There is some confusion
                with it. Origin and version of this jar bundled with production jetty is
                "glassfish javax.servlet.3.1.0.b33", while appserver-launcher jetty artifacts
                rely on the Orbit version and won't work with anything else. -->
            <dependency>
                <groupId>org.eclipse.jetty.orbit</groupId>
                <artifactId>javax.servlet</artifactId>
                <version>${servlet-api-version}</version>
            </dependency>
            <dependency>
                <groupId>org.slf4j</groupId>
                <artifactId>slf4j-api</artifactId>
                <version>${slf4j-version}</version>
            </dependency>
            <dependency>
                <groupId>org.slf4j</groupId>
                <artifactId>slf4j-simple</artifactId>
                <version>${slf4j-version}</version>
            </dependency>
            <dependency>
                <groupId>javax.ws.rs</groupId>
                <artifactId>javax.ws.rs-api</artifactId>
                <version>2.0</version>
            </dependency>
            <dependency>
                <groupId>org.glassfish.jersey.containers</groupId>
                <artifactId>jersey-container-servlet</artifactId>
                <version>${jersey-version}</version>
            </dependency>
            <dependency>
                <groupId>org.glassfish.jersey.test-framework</groupId>
                <artifactId>jersey-test-framework-core</artifactId>
                <version>${jersey-version}</version>
            </dependency>
            <dependency>
                <groupId>org.glassfish.jersey.test-framework.providers</groupId>
                <artifactId>jersey-test-framework-provider-inmemory</artifactId>
                <version>${jersey-version}</version>
            </dependency>
            <dependency>
                <groupId>com.fasterxml.jackson.core</groupId>
                <artifactId>jackson-core</artifactId>
                <version>${jackson-version}</version>
            </dependency>
            <dependency>
                <groupId>com.fasterxml.jackson.core</groupId>
                <artifactId>jackson-databind</artifactId>
                <version>${jackson-version}</version>
            </dependency>
            <dependency>
                <groupId>org.apache.cayenne</groupId>
                <artifactId>cayenne-server</artifactId>
                <version>${cayenne-version}</version>
            </dependency>
            <dependency>
                <groupId>org.apache.derby</groupId>
                <artifactId>derby</artifactId>
                <version>10.10.1.1</version>
            </dependency>
            <dependency>
                <groupId>commons-io</groupId>
                <artifactId>commons-io</artifactId>
                <version>1.3.2</version>
            </dependency>
        </dependencies>
    </dependencyManagement>

    <build>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-compiler-plugin</artifactId>
                    <version>2.5.1</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-jar-plugin</artifactId>
                    <version>2.6</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-enforcer-plugin</artifactId>
                    <version>1.4.1</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-javadoc-plugin</artifactId>
                    <version>2.9.1</version>
                    <configuration>
                        <!-- Java 8 is too strict about Javadoc omissions -->
                        <additionalparam>-Xdoclint:none</additionalparam>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-deploy-plugin</artifactId>
                    <version>2.8.1</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-gpg-plugin</artifactId>
                    <version>1.6</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-source-plugin</artifactId>
                    <version>2.4</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-release-plugin</artifactId>
                    <!-- Older versions of release plugin do not work with Git properly -->
                    <version>2.5.3</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-surefire-plugin</artifactId>
                    <version>2.18</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-failsafe-plugin</artifactId>
                    <version>2.18</version>
                    <executions>
                        <execution>
                            <id>integration-test</id>
                            <goals>
                                <goal>integration-test</goal>
                                <goal>verify</goal>
                            </goals>
                        </execution>
                    </executions>
                </plugin>
            </plugins>
        </pluginManagement>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-failsafe-plugin</artifactId>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-source-plugin</artifactId>
                <executions>
                    <execution>
                        <id>attach-sources</id>
                        <goals>
                            <goal>jar</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>
    <profiles>
        <!-- Release profile - sign artifacts; do extra checks to ensure we don't
            miss anything.. -->
        <profile>
            <id>release</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-gpg-plugin</artifactId>
                        <executions>
                            <execution>
                                <id>sign-artifacts</id>
                                <phase>verify</phase>
                                <goals>
                                    <goal>sign</goal>
                                </goals>
                            </execution>
                        </executions>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>

</project>
