<?xml version="1.0" encoding="UTF-8"?>

<!--
 ~  Copyright 2017 Red Hat, Inc.
 ~
 ~  Licensed under the Apache License, Version 2.0 (the "License");
 ~  you may not use this file except in compliance with the License.
 ~  You may obtain a copy of the License at
 ~
 ~    http://www.apache.org/licenses/LICENSE-2.0
 ~
 ~  Unless required by applicable law or agreed to in writing, software
 ~  distributed under the License is distributed on an "AS IS" BASIS,
 ~  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 ~  See the License for the specific language governing permissions and
 ~  limitations under the License.
  -->

<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>io.smallrye</groupId>
    <artifactId>smallrye-parent</artifactId>
    <version>37</version>
  </parent>

  <artifactId>smallrye-jwt-parent</artifactId>
  <version>3.6.0</version>

  <packaging>pom</packaging>
  <name>SmallRye: MicroProfile JWT Parent</name>
  <url>http://smallrye.io</url>

  <properties>
    <bouncycastle.version>1.70</bouncycastle.version>
    <version.jakarta.servlet.api>4.0.4</version.jakarta.servlet.api>
    <version.jakarta.security.enterprise.api>1.0.2</version.jakarta.security.enterprise.api>
    <version.eclipse.microprofile.jwt>1.2.2</version.eclipse.microprofile.jwt>
    <version.microprofile.config>2.0.1</version.microprofile.config>
    <version.jose4j>0.9.2</version.jose4j>
    <version.mokito>4.10.0</version.mokito>

    <!-- Test -->
    <artifactId.arquillian.jetty>arquillian-jetty-embedded-9</artifactId.arquillian.jetty>
    <version.arquillian.jetty>1.0.0.Final</version.arquillian.jetty>
    <version.jetty>9.4.50.v20221201</version.jetty>
    <version.resteasy>4.7.7.Final</version.resteasy>
    <version.smallrye.config>2.13.1</version.smallrye.config>
    <!-- RESTEasy REST Client relocated to another GAV, so these props are for jakarta auto migration -->
    <groupId.resteasy.client>org.jboss.resteasy</groupId.resteasy.client>
    <artifactId.resteasy.client>resteasy-client-microprofile</artifactId.resteasy.client>
    <version.resteasy.client>4.7.7.Final</version.resteasy.client>
    <!-- Wildfly -->
    <version.galleon>5.0.7.Final</version.galleon>
    <version.wildfly>25.0.1.Final</version.wildfly>
    <version.wildfly.plugin>4.0.0.Final</version.wildfly.plugin>
  </properties>

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

  <issueManagement>
    <system>GitHub</system>
    <url>https://github.com/smallrye/smallrye-jwt/issues</url>
  </issueManagement>

  <scm>
    <connection>scm:git:git@github.com:smallrye/smallrye-jwt.git</connection>
    <developerConnection>scm:git:git@github.com:smallrye/smallrye-jwt.git</developerConnection>
    <url>https://github.com/smallrye/smallrye-jwt/</url>
    <tag>3.6.0</tag>
  </scm>

  <modules>
    <module>implementation</module>
    <module>testsuite</module>
  </modules>

  <dependencyManagement>
    <dependencies>
      <dependency>
        <groupId>jakarta.servlet</groupId>
        <artifactId>jakarta.servlet-api</artifactId>
        <version>${version.jakarta.servlet.api}</version>
      </dependency>
      <dependency>
        <groupId>jakarta.security.enterprise</groupId>
        <artifactId>jakarta.security.enterprise-api</artifactId>
        <version>${version.jakarta.security.enterprise.api}</version>
      </dependency>
      <dependency>
        <groupId>org.eclipse.microprofile.jwt</groupId>
        <artifactId>microprofile-jwt-auth-api</artifactId>
        <version>${version.eclipse.microprofile.jwt}</version>
        <exclusions>
          <exclusion>
            <groupId>org.osgi</groupId>
            <artifactId>org.osgi.annotation.versioning</artifactId>
          </exclusion>
        </exclusions>
      </dependency>
      <dependency>
        <groupId>org.eclipse.microprofile.jwt</groupId>
        <artifactId>microprofile-jwt-auth-tck</artifactId>
        <version>${version.eclipse.microprofile.jwt}</version>
      </dependency>
      <dependency>
        <groupId>org.eclipse.microprofile.jwt</groupId>
        <artifactId>microprofile-jwt-auth-tck</artifactId>
        <type>test-jar</type>
        <version>${version.eclipse.microprofile.jwt}</version>
      </dependency>

      <dependency>
        <groupId>org.eclipse.microprofile.config</groupId>
        <artifactId>microprofile-config-api</artifactId>
        <version>${version.microprofile.config}</version>
      </dependency>

      <dependency>
        <groupId>org.bitbucket.b_c</groupId>
        <artifactId>jose4j</artifactId>
        <version>${version.jose4j}</version>
      </dependency>

      <!-- Dependencies provided by the project -->
      <dependency>
        <groupId>io.smallrye</groupId>
        <artifactId>smallrye-jwt</artifactId>
        <version>${project.version}</version>
      </dependency>
      <dependency>
        <groupId>io.smallrye</groupId>
        <artifactId>smallrye-jwt-common</artifactId>
        <version>${project.version}</version>
      </dependency>
      <dependency>
        <groupId>io.smallrye</groupId>
        <artifactId>smallrye-jwt-build</artifactId>
        <version>${project.version}</version>
      </dependency>
      <dependency>
        <groupId>io.smallrye</groupId>
        <artifactId>smallrye-jwt-jaxrs</artifactId>
        <version>${project.version}</version>
      </dependency>
      <dependency>
        <groupId>io.smallrye</groupId>
        <artifactId>smallrye-jwt-http-mechanism</artifactId>
        <version>${project.version}</version>
      </dependency>
      <dependency>
        <groupId>io.smallrye</groupId>
        <artifactId>smallrye-jwt-cdi-extension</artifactId>
        <version>${project.version}</version>
      </dependency>

      <!-- Unit/Integration test dependencies -->
      <dependency>
        <groupId>org.mockito</groupId>
        <artifactId>mockito-core</artifactId>
        <version>${version.mokito}</version>
      </dependency>
      <dependency>
        <groupId>org.bouncycastle</groupId>
        <artifactId>bcprov-jdk15on</artifactId>
        <version>${bouncycastle.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.arquillian.container</groupId>
        <artifactId>${artifactId.arquillian.jetty}</artifactId>
        <version>${version.arquillian.jetty}</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.eclipse.jetty</groupId>
        <artifactId>jetty-bom</artifactId>
        <version>${version.jetty}</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
      <dependency>
        <groupId>org.jboss.weld.servlet</groupId>
        <artifactId>weld-servlet-core</artifactId>
        <version>${version.weld.core}</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.jboss.resteasy</groupId>
        <artifactId>resteasy-bom</artifactId>
        <version>${version.resteasy}</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
      <dependency>
        <groupId>io.smallrye.config</groupId>
        <artifactId>smallrye-config</artifactId>
        <version>${version.smallrye.config}</version>
        <scope>test</scope>
      </dependency>
    </dependencies>
  </dependencyManagement>

  <profiles>
    <profile>
      <id>coverage</id>
      <properties>
        <argLine>@{jacocoArgLine}</argLine>
        <!--suppress UnresolvedMavenProperty -->
        <sonar.coverage.jacoco.xmlReportPaths>
          ${maven.multiModuleProjectDirectory}/coverage/target/site/jacoco-aggregate/jacoco.xml
        </sonar.coverage.jacoco.xmlReportPaths>
      </properties>
      <build>
        <plugins>
          <plugin>
            <groupId>org.jacoco</groupId>
            <artifactId>jacoco-maven-plugin</artifactId>
          </plugin>
        </plugins>
      </build>
      <modules>
        <module>coverage</module>
      </modules>
    </profile>
    <profile>
      <id>release</id>
      <activation>
        <property>
          <name>!release.maven.bug.always.be.active</name>
        </property>
      </activation>
      <modules>
        <module>release</module>
      </modules>
    </profile>
  </profiles>
</project>
