<?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>org.dataconservancy.pass</groupId>
  <artifactId>pass-client</artifactId>
  <packaging>pom</packaging>
  <version>0.4.2</version>
  <name>PASS Client Tool</name>
  <description>Client for interacting with the PASS Fedora+LDP repository</description>
  <url>https://github.com/OA-PASS/java-fedora-client</url>

  <licenses>
    <license>
      <name>The Apache Software License, Version 2.0</name>
      <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>
    </license>
  </licenses>

  <developers>
    <developer>
      <name>Aaron Birkland</name>
      <email>apb@jhu.edu</email>
      <organization>The Sheridan Libraries, Johns Hopkins Univeristy</organization>
      <organizationUrl>https://www.library.jhu.edu/</organizationUrl>
    </developer>
    <developer>
      <name>Karen Hanson</name>
      <email>karen.hanson@jhu.edu</email>
      <organization>The Sheridan Libraries, Johns Hopkins Univeristy</organization>
      <organizationUrl>https://www.library.jhu.edu/</organizationUrl>
    </developer>
    <developer>
      <name>Jim Martino</name>
      <email>jrm.jhu@jhu.edu</email>
      <organization>The Sheridan Libraries, Johns Hopkins Univeristy</organization>
      <organizationUrl>https://www.library.jhu.edu/</organizationUrl>
    </developer>
    <developer>
      <name>Elliot Metsger</name>
      <email>emetsger@jhu.edu</email>
      <organization>The Sheridan Libraries, Johns Hopkins Univeristy</organization>
      <organizationUrl>https://www.library.jhu.edu/</organizationUrl>
    </developer>
    <developer>
      <name>Mark Patton</name>
      <email>mpatton@jhu.edu</email>
      <organization>The Sheridan Libraries, Johns Hopkins Univeristy</organization>
      <organizationUrl>https://www.library.jhu.edu/</organizationUrl>
    </developer>
    <developer>
      <name>Hanh Vu</name>
      <email>hanh.vu@jhu.edu</email>
      <organization>The Sheridan Libraries, Johns Hopkins Univeristy</organization>
      <organizationUrl>https://www.library.jhu.edu/</organizationUrl>
    </developer>
  </developers>

  <modules>
    <module>pass-model</module>
    <module>pass-json-adapter</module>
    <module>pass-data-client</module>
    <module>pass-client-api</module>
    <module>pass-client-util</module>
    <module>pass-client-integration</module>
    <module>pass-test-data</module>
    <module>pass-client-shaded-v2_3</module>
    <module>pass-status-service</module>
  </modules>

  <profiles>

    <profile>
      <id>external</id>
      <activation>
        <property>
          <name>external</name>
        </property>
      </activation>
      <properties>
        <scp.port>122</scp.port>
      </properties>
    </profile>

    <profile>
      <id>release</id>
      <build>
        <pluginManagement>
          <plugins>
            <plugin>
              <artifactId>maven-gpg-plugin</artifactId>
              <version>${maven-gpg-plugin.version}</version>
              <executions>
                <execution>
                  <id>sign-artifacts</id>
                  <phase>verify</phase>
                  <goals>
                    <goal>sign</goal>
                  </goals>
                </execution>
              </executions>
              <configuration>
                <useAgent>true</useAgent>
              </configuration>
            </plugin>
          </plugins>
        </pluginManagement>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-gpg-plugin</artifactId>
          </plugin>
        </plugins>
      </build>
    </profile>

  </profiles>

  <properties>
    <scp.port>22</scp.port>

    <build-helper-maven-plugin.version>3.0.0</build-helper-maven-plugin.version>
    <docker-maven-plugin.version>0.27.2</docker-maven-plugin.version>
    <maven-compiler-plugin.version>3.8.0</maven-compiler-plugin.version>
    <maven-failsafe-plugin.version>2.22.0</maven-failsafe-plugin.version>
    <maven-gpg-plugin.version>1.6</maven-gpg-plugin.version>
    <maven-javadoc-pugin.version>3.0.1</maven-javadoc-pugin.version>
    <maven-release-plugin.version>2.5.3</maven-release-plugin.version>
    <maven-surefire-plugin.version>2.22.0</maven-surefire-plugin.version>
    <maven-source-plugin.version>3.0.1</maven-source-plugin.version>
    <maven.deploy.plugin.version>2.8.2</maven.deploy.plugin.version>
    <maven.wagon.ssh.version>3.2.0</maven.wagon.ssh.version>

    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>

    <commons-io.version>2.6</commons-io.version>
    <commons-beanutils.version>1.9.3</commons-beanutils.version>
    <joda-time.version>2.10</joda-time.version>
    <org-json.version>20180813</org-json.version>
    <junit.version>4.12</junit.version>
    <jackson.version>2.9.7</jackson.version>
    <fcrepo-java-client.version>0.3.0</fcrepo-java-client.version>
    <logback.version>1.2.3</logback.version>
    <mockito.version>2.23.0</mockito.version>
    <openpojo.version>0.8.10</openpojo.version>
    <elasticsearch-client.version>6.2.4</elasticsearch-client.version>
    <slf4j.version>1.7.25</slf4j.version>
    <unitils.version>3.4.6</unitils.version>
    <okhttp.version>3.11.0</okhttp.version>
    <log4j2.version>2.11.1</log4j2.version>
  </properties>

  <build>
    <pluginManagement>
      <plugins>
        <plugin>
          <artifactId>maven-compiler-plugin</artifactId>
          <version>${maven-compiler-plugin.version}</version>
          <configuration>
            <source>1.8</source>
            <target>1.8</target>
          </configuration>
        </plugin>

        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-source-plugin</artifactId>
          <version>${maven-source-plugin.version}</version>
          <executions>
            <execution>
              <goals>
                <goal>jar</goal>
              </goals>
            </execution>
          </executions>
        </plugin>

        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-javadoc-plugin</artifactId>
          <version>${maven-javadoc-pugin.version}</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>${maven-gpg-plugin.version}</version>
          <executions>
            <execution>
              <id>sign-artifacts</id>
              <phase>verify</phase>
              <goals>
                <goal>sign</goal>
              </goals>
            </execution>
          </executions>
          <configuration>
            <useAgent>true</useAgent>
          </configuration>
        </plugin>

        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-surefire-plugin</artifactId>
          <version>${maven-surefire-plugin.version}</version>
        </plugin>

        <plugin>
          <artifactId>maven-deploy-plugin</artifactId>
          <version>${maven.deploy.plugin.version}</version>
          <configuration>
            <retryFailedDeploymentCount>5</retryFailedDeploymentCount>
          </configuration>
          <!-- See https://jira.codehaus.org/browse/WAGON-393 -->
          <dependencies>
            <dependency>
              <groupId>org.apache.maven.wagon</groupId>
              <artifactId>wagon-ssh</artifactId>
              <version>${maven.wagon.ssh.version}</version>
            </dependency>
          </dependencies>
        </plugin>

        <plugin>
          <groupId>io.fabric8</groupId>
          <artifactId>docker-maven-plugin</artifactId>
          <version>${docker-maven-plugin.version}</version>
        </plugin>

        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>build-helper-maven-plugin</artifactId>
          <version>${build-helper-maven-plugin.version}</version>
        </plugin>

        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-release-plugin</artifactId>
          <version>${maven-release-plugin.version}</version>
          <configuration>
            <preparationGoals>clean install</preparationGoals>
            <releaseProfiles>release</releaseProfiles>
          </configuration>
        </plugin>

        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-failsafe-plugin</artifactId>
          <version>${maven-failsafe-plugin.version}</version>
        </plugin>

      </plugins>
    </pluginManagement>

    <plugins>
      <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-release-plugin</artifactId>
      </plugin>

    </plugins>

  </build>

  <dependencyManagement>
    <dependencies>
      <dependency>
        <groupId>org.slf4j</groupId>
        <artifactId>slf4j-api</artifactId>
        <version>${slf4j.version}</version>
      </dependency>

      <dependency>
        <groupId>org.fcrepo.client</groupId>
        <artifactId>fcrepo-java-client</artifactId>
        <version>${fcrepo-java-client.version}</version>
      </dependency>

      <dependency>
        <groupId>com.fasterxml.jackson.core</groupId>
        <artifactId>jackson-databind</artifactId>
        <version>${jackson.version}</version>
      </dependency>

      <dependency>
        <groupId>joda-time</groupId>
        <artifactId>joda-time</artifactId>
        <version>${joda-time.version}</version>
      </dependency>

      <dependency>
        <groupId>org.json</groupId>
        <artifactId>json</artifactId>
        <version>${org-json.version}</version>
        <scope>test</scope>
      </dependency>

      <dependency>
        <groupId>junit</groupId>
        <artifactId>junit</artifactId>
        <version>${junit.version}</version>
        <scope>test</scope>
      </dependency>

      <dependency>
        <groupId>ch.qos.logback</groupId>
        <artifactId>logback-classic</artifactId>
        <version>${logback.version}</version>
        <scope>test</scope>
      </dependency>

      <dependency>
        <groupId>commons-io</groupId>
        <artifactId>commons-io</artifactId>
        <version>${commons-io.version}</version>
      </dependency>

      <dependency>
        <groupId>org.elasticsearch.client</groupId>
        <artifactId>elasticsearch-rest-high-level-client</artifactId>
        <version>${elasticsearch-client.version}</version>
        <exclusions>
          <exclusion>
            <groupId>org.apache.logging.log4j</groupId>
            <artifactId>log4j-api</artifactId>
          </exclusion>
          <exclusion>
            <groupId>commons-logging</groupId>
            <artifactId>commons-logging</artifactId>
          </exclusion>
          <exclusion>
            <groupId>org.apache.logging.log4j</groupId>
            <artifactId>log4j-core</artifactId>
          </exclusion>
        </exclusions>
      </dependency>

      <dependency>
        <groupId>org.unitils</groupId>
        <artifactId>unitils-core</artifactId>
        <version>${unitils.version}</version>
        <scope>test</scope>
        <exclusions>
          <exclusion>
            <groupId>commons-logging</groupId>
            <artifactId>commons-logging</artifactId>
          </exclusion>
        </exclusions>
      </dependency>

      <dependency>
        <groupId>org.slf4j</groupId>
        <artifactId>log4j-over-slf4j</artifactId>
        <version>${slf4j.version}</version>
      </dependency>

      <dependency>
        <groupId>org.apache.logging.log4j</groupId>
        <artifactId>log4j-to-slf4j</artifactId>
        <version>${log4j2.version}</version>
      </dependency>

      <dependency>
        <groupId>org.slf4j</groupId>
        <artifactId>jcl-over-slf4j</artifactId>
        <version>${slf4j.version}</version>
      </dependency>

      <dependency>
        <groupId>commons-beanutils</groupId>
        <artifactId>commons-beanutils</artifactId>
        <version>${commons-beanutils.version}</version>
        <exclusions>
          <exclusion>
            <groupId>commons-logging</groupId>
            <artifactId>commons-logging</artifactId>
          </exclusion>
        </exclusions>
      </dependency>

      <dependency>
        <groupId>com.openpojo</groupId>
        <artifactId>openpojo</artifactId>
        <version>${openpojo.version}</version>
        <scope>test</scope>
      </dependency>

      <dependency>
        <groupId>com.squareup.okhttp3</groupId>
        <artifactId>okhttp</artifactId>
        <version>${okhttp.version}</version>
      </dependency>

      <dependency>
        <groupId>com.squareup.okhttp3</groupId>
        <artifactId>logging-interceptor</artifactId>
        <version>${okhttp.version}</version>
      </dependency>

      <dependency>
        <groupId>org.mockito</groupId>
        <artifactId>mockito-core</artifactId>
        <version>${mockito.version}</version>
        <scope>test</scope>
      </dependency>
    </dependencies>
  </dependencyManagement>

  <distributionManagement>

    <repository>
      <id>maven-central-staging</id>
      <url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
    </repository>

    <snapshotRepository>
      <id>dc.public.snapshots</id>
      <name>Data Conservancy Snapshot Maven Repository</name>
      <url>scp://maven.dataconservancy.org:${scp.port}/data/maven-dc/public/snapshots/</url>
      <uniqueVersion>false</uniqueVersion>
    </snapshotRepository>

  </distributionManagement>

  <repositories>
    <repository>
      <id>oss</id>
      <url>https://oss.sonatype.org/content/repositories/snapshots</url>
      <snapshots>
        <enabled>true</enabled>
      </snapshots>
      <releases>
        <enabled>false</enabled>
      </releases>
    </repository>
    <repository>
      <id>dc.public.snapshots</id>
      <name>Data Conservancy Public Maven Repository (snapshots)</name>
      <layout>default</layout>
      <url>http://maven.dataconservancy.org/public/snapshots/</url>
      <releases>
        <enabled>false</enabled>
      </releases>
      <snapshots>
        <enabled>true</enabled>
      </snapshots>
    </repository>
  </repositories>


  <scm>
    <connection>scm:git:https://github.com/OA-PASS/java-fedora-client.git</connection>
    <developerConnection>scm:git:https://github.com/OA-PASS/java-fedora-client.git</developerConnection>
    <url>https://github.com/OA-PASS/java-fedora-client</url>
    <tag>0.4.2</tag>
  </scm>

</project>
