<?xml version='1.0' encoding='UTF-8'?>
<!--
~ Copyright 2016 Red Hat, Inc. and/or its affiliates
~ and other contributors as indicated by the @author tags.
~
~ 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/maven-v4_0_0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <parent>
        <groupId>org.jboss</groupId>
        <artifactId>jboss-parent</artifactId>
        <version>39</version>
    </parent>

    <name>Keycloak Client Libraries</name>
    <description>
        Keycloak Client Libraries
    </description>
    <groupId>org.keycloak</groupId>
    <artifactId>keycloak-client-parent</artifactId>
    <version>26.0.8</version>
    <packaging>pom</packaging>

    <properties>
        <keycloak.version>999.0.0-SNAPSHOT</keycloak.version>
        <asciidoctor.plugin.version>1.5.8</asciidoctor.plugin.version>
        <freemarker.version>2.3.32</freemarker.version>

        <!-- Quarkus aligned versions -->
        <resteasy.version>6.2.12.Final</resteasy.version>
        <com.fasterxml.jackson.version>2.19.2</com.fasterxml.jackson.version>
        <microprofile-openapi-api.version>4.0.2</microprofile-openapi-api.version>
        <jboss-logging.version>3.6.1.Final</jboss-logging.version>
        <commons-logging-jboss-logging.version>1.0.0.Final</commons-logging-jboss-logging.version>
        <httpclient.version>4.5.14</httpclient.version>
        <jakarta.servlet-api.version>6.0.0</jakarta.servlet-api.version>

        <project.build-time>${timestamp}</project.build-time>

        <log4j.version>1.2.17</log4j.version>
        <wildfly-elytron.version>2.6.5.Final</wildfly-elytron.version>

        <!-- Needs to be aligned with Quarkus, see e.g. https://github.com/quarkusio/quarkus-quickstarts/blob/2.13.5.Final/getting-started-async/pom.xml#L14 -->
        <surefire-plugin.version>3.5.3</surefire-plugin.version>

        <!-- Maven Plugins -->
        <maven.version>3.9.8</maven.version>
        <maven.compiler.source>8</maven.compiler.source>
        <maven.compiler.target>8</maven.compiler.target>
        <maven.compiler.release>8</maven.compiler.release>
        <maven.plugins.version>3.11.0</maven.plugins.version>
        <replacer.plugin.version>1.4.1</replacer.plugin.version>
        <central.publishing.plugin.version>0.7.0</central.publishing.plugin.version>
        <verifier.plugin.version>1.1</verifier.plugin.version>
        <build-helper-maven-plugin.version>3.2.0</build-helper-maven-plugin.version>

        <!-- Surefire Settings -->
        <surefire.memory.Xms>512m</surefire.memory.Xms>
        <surefire.memory.Xmx>2048m</surefire.memory.Xmx>
        <surefire.memory.metaspace>96m</surefire.memory.metaspace>
        <surefire.memory.metaspace.max>512m</surefire.memory.metaspace.max>
        <surefire.memory.settings>-Xms${surefire.memory.Xms} -Xmx${surefire.memory.Xmx} -XX:MetaspaceSize=${surefire.memory.metaspace} -XX:MaxMetaspaceSize=${surefire.memory.metaspace.max}</surefire.memory.settings>
        <surefire.system.args></surefire.system.args>

    </properties>

    <url>https://keycloak.org</url>

    <licenses>
        <license>
            <name>Apache License, Version 2.0</name>
            <url>https://www.apache.org/licenses/LICENSE-2.0</url>
            <distribution>repo</distribution>
        </license>
    </licenses>

    <scm>
        <connection>scm:git:git://github.com/keycloak/keycloak-client.git</connection>
        <developerConnection>scm:git:git@github.com:keycloak/keycloak-client.git</developerConnection>
        <url>https://github.com/keycloak/keycloak-client/tree/master/</url>
    </scm>

    <distributionManagement>
        <repository>
            <id>keycloak-publish</id>
            <url>https://central.sonatype.com/</url>
        </repository>
        <snapshotRepository>
            <id>keycloak-publish</id>
            <url>https://central.sonatype.com/repository/maven-snapshots/</url>
        </snapshotRepository>
    </distributionManagement>

    <issueManagement>
        <system>JIRA</system>
        <url>https://github.com/keycloak/keycloak-client/issues</url>
    </issueManagement>

    <developers>
        <developer>
            <id>keycloak</id>
            <name>Keycloak Team</name>
        </developer>
    </developers>

    <contributors></contributors>

    <modules>
        <module>client-common-synced</module>
        <module>admin-client</module>
        <module>authz-client</module>
        <module>policy-enforcer</module>
        <module>docs</module>
        <module>testsuite</module>
    </modules>

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>org.keycloak</groupId>
                <artifactId>keycloak-client-common-synced</artifactId>
                <version>${project.version}</version>
            </dependency>
            <dependency>
                <groupId>org.jboss.logging</groupId>
                <artifactId>jboss-logging</artifactId>
                <version>${jboss-logging.version}</version>
            </dependency>
            <dependency>
                <groupId>com.fasterxml.jackson.core</groupId>
                <artifactId>jackson-core</artifactId>
                <version>${com.fasterxml.jackson.version}</version>
            </dependency>
            <dependency>
                <groupId>com.fasterxml.jackson.core</groupId>
                <artifactId>jackson-databind</artifactId>
                <version>${com.fasterxml.jackson.version}</version>
            </dependency>
            <dependency>
                <groupId>com.fasterxml.jackson.core</groupId>
                <artifactId>jackson-annotations</artifactId>
                <version>${com.fasterxml.jackson.version}</version>
            </dependency>
            <dependency>
                <groupId>com.fasterxml.jackson.datatype</groupId>
                <artifactId>jackson-datatype-jdk8</artifactId>
                <version>${com.fasterxml.jackson.version}</version>
            </dependency>
            <dependency>
                <groupId>com.fasterxml.jackson.datatype</groupId>
                <artifactId>jackson-datatype-jsr310</artifactId>
                <version>${com.fasterxml.jackson.version}</version>
            </dependency>
            <dependency>
                <groupId>com.fasterxml.jackson.jaxrs</groupId>
                <artifactId>jackson-jaxrs-json-provider</artifactId>
                <version>${com.fasterxml.jackson.version}</version>
            </dependency>
            <dependency>
                <groupId>com.fasterxml.jackson.jakarta.rs</groupId>
                <artifactId>jackson-jakarta-rs-yaml-provider</artifactId>
                <version>${com.fasterxml.jackson.version}</version>
            </dependency>
            <dependency>
                <groupId>org.jboss.logging</groupId>
                <artifactId>commons-logging-jboss-logging</artifactId>
                <version>${commons-logging-jboss-logging.version}</version>
            </dependency>
            <dependency>
                <groupId>org.apache.httpcomponents</groupId>
                <artifactId>httpclient</artifactId>
                <version>${httpclient.version}</version>
                <exclusions>
                    <exclusion>
                        <groupId>commons-logging</groupId>
                        <artifactId>*</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>
            <dependency>
                <groupId>jakarta.servlet</groupId>
                <artifactId>jakarta.servlet-api</artifactId>
                <version>${jakarta.servlet-api.version}</version>
            </dependency>
            <dependency>
                <groupId>org.eclipse.microprofile.openapi</groupId>
                <artifactId>microprofile-openapi-api</artifactId>
                <version>${microprofile-openapi-api.version}</version>
            </dependency>

            <dependency>
                <groupId>org.jboss.resteasy</groupId>
                <artifactId>resteasy-core</artifactId>
                <version>${resteasy.version}</version>
                <exclusions>
                    <exclusion>
                        <groupId>log4j</groupId>
                        <artifactId>log4j</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>org.slf4j</groupId>
                        <artifactId>slf4j-api</artifactId>
                    </exclusion>
                    <exclusion>
                        <groupId>org.slf4j</groupId>
                        <artifactId>slf4j-simple</artifactId>
                    </exclusion>
                </exclusions>
            </dependency>
            <dependency>
                <groupId>org.jboss.resteasy</groupId>
                <artifactId>resteasy-core-spi</artifactId>
                <version>${resteasy.version}</version>
            </dependency>
            <dependency>
                <groupId>org.jboss.resteasy</groupId>
                <artifactId>resteasy-multipart-provider</artifactId>
                <version>${resteasy.version}</version>
            </dependency>
            <dependency>
                <groupId>org.jboss.resteasy</groupId>
                <artifactId>resteasy-jackson2-provider</artifactId>
                <version>${resteasy.version}</version>
            </dependency>
            <dependency>
                <groupId>org.jboss.resteasy</groupId>
                <artifactId>resteasy-jaxb-provider</artifactId>
                <version>${resteasy.version}</version>
            </dependency>
            <dependency>
                <groupId>org.jboss.resteasy</groupId>
                <artifactId>resteasy-client</artifactId>
                <version>${resteasy.version}</version>
            </dependency>
            <dependency>
                <groupId>log4j</groupId>
                <artifactId>log4j</artifactId>
                <version>${log4j.version}</version>
            </dependency>

            <dependency>
                <groupId>org.wildfly.security</groupId>
                <artifactId>wildfly-elytron-http-oidc</artifactId>
                <version>${wildfly-elytron.version}</version>
            </dependency>

            <!-- Authorization -->
            <dependency>
                <groupId>org.keycloak</groupId>
                <artifactId>keycloak-authz-client</artifactId>
                <version>${project.version}</version>
            </dependency>

            <!-- freemarker for guides -->
            <dependency>
                <groupId>org.freemarker</groupId>
                <artifactId>freemarker</artifactId>
                <version>${freemarker.version}</version>
            </dependency>
        </dependencies>
    </dependencyManagement>

    <build>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-dependency-plugin</artifactId>
                    <version>3.1.2</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-release-plugin</artifactId>
                    <version>2.5.2</version>
                    <configuration>
                        <autoVersionSubmodules>true</autoVersionSubmodules>
                        <tagNameFormat>@{project.version}</tagNameFormat>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-surefire-plugin</artifactId>
                    <version>${surefire-plugin.version}</version>
                    <configuration>
                        <argLine>-Djava.awt.headless=true ${surefire.memory.settings} ${surefire.system.args} -Duser.language=en -Duser.region=US -XX:+ExitOnOutOfMemoryError -XX:+HeapDumpOnOutOfMemoryError</argLine>
                        <runOrder>alphabetical</runOrder>
                        <failIfNoSpecifiedTests>false</failIfNoSpecifiedTests>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-jar-plugin</artifactId>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-plugin-plugin</artifactId>
                    <version>${maven.plugins.version}</version>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-install-plugin</artifactId>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-verifier-plugin</artifactId>
                    <version>${verifier.plugin.version}</version>
                    <executions>
                        <execution>
                            <id>main</id>
                            <phase>verify</phase>
                            <goals>
                                <goal>verify</goal>
                            </goals>
                        </execution>
                    </executions>
                    <configuration>
                        <verificationFile>target/verifier/verifications.xml</verificationFile>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.apache.maven.plugins</groupId>
                    <artifactId>maven-clean-plugin</artifactId>
                    <configuration>
                        <followSymLinks>false</followSymLinks>
                    </configuration>
                </plugin>
                <plugin>
                    <groupId>org.asciidoctor</groupId>
                    <artifactId>asciidoctor-maven-plugin</artifactId>
                    <version>${asciidoctor.plugin.version}</version>
                </plugin>
                <plugin>
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>build-helper-maven-plugin</artifactId>
                    <version>${build-helper-maven-plugin.version}</version>
                </plugin>
            </plugins>
        </pluginManagement>
    </build>

    <profiles>
        <profile>
            <id>nightly</id>
            <activation>
                <property>
                    <name>nightly</name>
                </property>
            </activation>
            <repositories>
                <repository>
                    <id>sonatype-snapshots</id>
                    <name>Sonatype Snapshots</name>
                    <url>https://central.sonatype.com/repository/maven-snapshots/</url>
                    <snapshots>
                        <enabled>true</enabled>
                        <updatePolicy>daily</updatePolicy>
                    </snapshots>
                    <releases>
                        <enabled>false</enabled>
                    </releases>
                </repository>
            </repositories>
        </profile>
        <profile>
            <id>jdk9</id>
            <activation>
                <jdk>[9,)</jdk>
            </activation>
            <properties>
                <surefire.system.args>
                    --add-opens=java.base/java.lang=ALL-UNNAMED
                    --add-opens=java.base/java.util=ALL-UNNAMED
                </surefire.system.args>
            </properties>
        </profile>

        <profile>
            <id>doclint-java8-disable</id>
            <activation>
                <jdk>[1.8,)</jdk>
            </activation>

            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-javadoc-plugin</artifactId>
                        <configuration>
                            <doclint>none</doclint>
                            <failOnError>false</failOnError>
                            <excludePackageNames>cx.*:org.freedesktop*:org.jvnet*</excludePackageNames>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>

        <profile>
            <id>central-staging</id>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.sonatype.central</groupId>
                        <artifactId>central-publishing-maven-plugin</artifactId>
                        <version>${central.publishing.plugin.version}</version>
                        <extensions>true</extensions>
                        <configuration>
                            <autoPublish>true</autoPublish>
                            <checksums>all</checksums>
                            <deploymentName>keycloak-${project.version}</deploymentName>
                            <publishingServerId>keycloak-publish</publishingServerId>
                            <waitUntil>published</waitUntil>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>

        <profile>
            <id>gpg</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>
                                <configuration>
                                    <gpgArguments>
                                        <arg>--batch</arg>
                                        <arg>--pinentry-mode</arg>
                                        <arg>loopback</arg>
                                    </gpgArguments>
                                </configuration>
                            </execution>
                        </executions>
                        <configuration>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>

   </profiles>
</project>
