<?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>com.adobe.documentservices</groupId>
  <artifactId>pdfservices-sdk</artifactId>
  <version>4.3.0</version>
  <name>PDF Services SDK</name>
  <packaging>jar</packaging>

  <developers>
    <developer>
      <id>Adobe</id>
      <name>Adobe</name>
      <organization>Adobe</organization>
    </developer>
  </developers>
  <scm>
    <url>${scm.url}</url>
  </scm>

  <organization>
    <name>Adobe</name>
    <url>https://www.adobe.com</url>
  </organization>

  <description>Adobe PDF Services SDK allows you to access RESTful APIs to create, convert, and manipulate PDFs within your applications.</description>

  <url>http://www.adobe.com/go/pdftoolsapi_doc</url>

  <licenses>
    <license>
      <name>License Agreement</name>
      <url>http://adobe.com/go/terms</url>
      <distribution>repo</distribution>
    </license>
  </licenses>


  <properties>
    <hibernate.validator.version>6.2.1.Final</hibernate.validator.version>
    <httpcomponents.version>4.5.14</httpcomponents.version>
  </properties>

  <dependencies>

    <!--Library for logging abstraction-->
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-api</artifactId>
      <version>2.0.9</version>
    </dependency>

    <!--Library for json serialization and deserialization-->
    <dependency>
      <groupId>com.fasterxml.jackson.core</groupId>
      <artifactId>jackson-databind</artifactId>
      <version>2.16.0</version>
    </dependency>

    <!--Library for HTTP client and API calls-->
    <dependency>
      <groupId>org.apache.httpcomponents</groupId>
      <artifactId>httpclient</artifactId>
      <version>${httpcomponents.version}</version>
    </dependency>

    <!--Library which supports request builders for apache http client-->
    <dependency>
      <groupId>org.apache.httpcomponents</groupId>
      <artifactId>httpmime</artifactId>
      <version>${httpcomponents.version}</version>
    </dependency>

    <!--Library for supporting HTTP retries-->
    <dependency>
      <groupId>net.jodah</groupId>
      <artifactId>failsafe</artifactId>
      <version>2.4.4</version>
    </dependency>

    <!-- Library for util operations on file like fetching base name and extension, moving and copying -->
    <dependency>
      <groupId>commons-io</groupId>
      <artifactId>commons-io</artifactId>
      <version>2.15.1</version>
    </dependency>

    <!-- Dependency for parsing JSON  -->
    <dependency>
      <groupId>org.json</groupId>
      <artifactId>json</artifactId>
      <version>20231013</version>
    </dependency>

  </dependencies>

  <profiles>
    <profile>
      <id>release</id>
      <properties>
        <scm.url>https://github.com/adobe/</scm.url>
        <dev.email>dcpfsdk@adobe.com</dev.email>
      </properties>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-gpg-plugin</artifactId>
            <version>3.1.0</version>
            <executions>
              <execution>
                <id>sign-artifacts</id>
                <phase>verify</phase>
                <goals>
                  <goal>sign</goal>
                </goals>
                <configuration>
                  <passphrase>${gpg.passphrase}</passphrase>
                </configuration>
              </execution>
            </executions>
          </plugin>
          <plugin>
            <groupId>org.sonatype.plugins</groupId>
            <artifactId>nexus-staging-maven-plugin</artifactId>
            <version>1.6.13</version>
            <extensions>true</extensions>
            <configuration>
              <serverId>ossrh</serverId>
              <nexusUrl>https://oss.sonatype.org/</nexusUrl>
              <autoReleaseAfterClose>false</autoReleaseAfterClose>
            </configuration>
          </plugin>
        </plugins>
      </build>
    </profile>
    <profile>
      <id>default</id>
      <activation>
        <activeByDefault>true</activeByDefault>
      </activation>
      <properties>
        <scm.url>https://git.corp.adobe.com/dc/pdftools-sdk</scm.url>
        <dev.email>Grp-Andes@adobe.com</dev.email>
      </properties>
    </profile>
  </profiles>

  <build>
    <resources>
      <resource>
        <directory>src/main/resources</directory>
        <filtering>true</filtering>
      </resource>
    </resources>

    <plugins>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-compiler-plugin</artifactId>
        <configuration>
          <source>11</source>
          <target>11</target>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-source-plugin</artifactId>
        <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>3.6.2</version>
        <executions>
          <execution>
            <goals>
              <goal>javadoc</goal>
              <goal>jar</goal>
            </goals>
            <configuration>
              <windowtitle>Adobe PDF Services SDK Specification</windowtitle>
              <doctitle>Adobe PDF Services SDK Specification</doctitle>
              <header>PDF Services SDK</header>
              <outputDirectory>${basedir}/docs</outputDirectory>
              <reportOutputDirectory>${basedir}/docs</reportOutputDirectory>
              <excludePackageNames>com.adobe.pdfservices.operation.internal:com.adobe.pdfservices.operation.internal.*:com.adobe.pdfservices.operation.internal.auth.*:com.adobe.pdfservices.operation.internal.constants.*:com.adobe.pdfservices.operation.internal.dto.*:com.adobe.pdfservices.operation.internal.dto.request.*:com.adobe.pdfservices.operation.internal.dto.response.*:com.adobe.pdfservices.operation.internal.http.*</excludePackageNames>
              <subpackages>
                com.adobe.pdfservices.operation:com.adobe.pdfservices.operation.pdfjobs.jobs:com.adobe.pdfservices.operation.pdfjobs.params:com.adobe.pdfservices.operation.pdfjobs.result:com.adobe.pdfservices.operation.exception:com.adobe.pdfservices.operation.io:
              </subpackages>
              <sourcepath>${basedir}/src/main/java</sourcepath>
              <show>public</show>
            </configuration>
          </execution>

        </executions>

      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-jar-plugin</artifactId>
        <version>3.3.0</version>
        <configuration>
          <archive>
            <manifestEntries>
              <Automatic-Module-Name>com.adobe.pdfservices</Automatic-Module-Name>
            </manifestEntries>
            <!-- Make sure MANIFEST.MF generated by maven-bundle-plugin is used for final JAR -->
            <manifestFile>${project.build.outputDirectory}/META-INF/MANIFEST.MF</manifestFile>
            <manifest>
              <addDefaultImplementationEntries>true</addDefaultImplementationEntries>
              <addDefaultSpecificationEntries>true</addDefaultSpecificationEntries>
            </manifest>
          </archive>
        </configuration>
        <executions>
          <execution>
            <id>default-jar</id>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.felix</groupId>
        <artifactId>maven-bundle-plugin</artifactId>
        <version>5.1.9</version>
        <extensions>true</extensions>
        <configuration>
          <instructions>
            <Private-Package>
              com.adobe.pdfservices.operation.internal.*
            </Private-Package>
            <Export-Package>
              com.adobe.pdfservices.operation,
              com.adobe.pdfservices.operation.auth,
              com.adobe.pdfservices.operation.config.*,
              com.adobe.pdfservices.operation.exception,
              com.adobe.pdfservices.operation.io.*,
              com.adobe.pdfservices.operation.pdfjobs.*,
            </Export-Package>
            <Import-Package>*</Import-Package>
            <Include-Resource>{maven-resources}</Include-Resource>
          </instructions>
        </configuration>
        <executions>
          <execution>
            <id>bundle-manifest</id>
            <phase>process-classes</phase>
            <goals>
              <goal>manifest</goal>
            </goals>
          </execution>
        </executions>
      </plugin>

    </plugins>
  </build>
</project>
