<project xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xmlns="http://maven.apache.org/POM/4.0.0"
         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>io.confluent</groupId>
        <artifactId>rest-utils-parent</artifactId>
        <version>7.8.6</version>
    </parent>

    <artifactId>kafka-secret-registry-parent</artifactId>
    <packaging>pom</packaging>
    <name>kafka-secret-registry-parent</name>
    <version>7.8.6</version>
    <organization>
        <name>Confluent, Inc.</name>
        <url>http://confluent.io</url>
    </organization>
    <url>http://confluent.io</url>
    <description>
        Secret Registry provides a RESTful interface for storing and retrieving versioned secrets.
    </description>

    <licenses>
        <license>
            <name>Confluent License Agreement</name>
            <url>https://www.confluent.io/legal/confluent-license-agreement/</url>
            <distribution>repo</distribution>
        </license>
    </licenses>

    <scm>
        <connection>scm:git:git://github.com/confluentinc/secret-registry.git</connection>
        <developerConnection>scm:git:git@github.com:confluentinc/secret-registry.git</developerConnection>
        <url>https://github.com/confluentinc/secret-registry</url>
        <tag>HEAD</tag>
    </scm>

    <modules>
        <module>core</module>
        <module>client</module>
        <module>package-secret-registry</module>
        <module>secret-registry-console-scripts</module>
    </modules>

    <properties>
        <apache.directory.server.version>2.0.0-M22</apache.directory.server.version>
        <apache.directory.api.version>1.0.0-M33</apache.directory.api.version>
        <checkstyle.suppressions.location>checkstyle/suppressions.xml</checkstyle.suppressions.location>
        <confluent.maven.repo>https://packages.confluent.io/maven/</confluent.maven.repo>
        <exec-maven-plugin.version>1.2.1</exec-maven-plugin.version>
        <kafka.version>${ce.kafka.version}</kafka.version>
        <kafka.connect.maven.plugin.version>0.11.1</kafka.connect.maven.plugin.version>
        <podam.version>6.0.2.RELEASE</podam.version>
        <io.confluent.secret-registry.version>7.8.6</io.confluent.secret-registry.version>
        <io.confluent.confluent-security-plugins.version>${confluent.version.range}</io.confluent.confluent-security-plugins.version>
        <cc.role.definitions.version>0.29.0</cc.role.definitions.version>
    </properties>

    <repositories>
        <repository>
            <id>confluent</id>
            <name>Confluent</name>
            <url>${confluent.maven.repo}</url>
        </repository>
    </repositories>

    <dependencyManagement>
        <dependencies>
            <dependency>
                <groupId>uk.co.jemos.podam</groupId>
                <artifactId>podam</artifactId>
                <version>${podam.version}</version>
            </dependency>

            <!--children-->
            <dependency>
                <groupId>io.confluent</groupId>
                <artifactId>kafka-secret-registry-client</artifactId>
                <version>${io.confluent.secret-registry.version}</version>
            </dependency>
            <dependency>
                <groupId>io.confluent</groupId>
                <artifactId>kafka-secret-registry</artifactId>
                <version>${io.confluent.secret-registry.version}</version>
            </dependency>
            <dependency>
                <groupId>io.confluent</groupId>
                <artifactId>confluent-connect-secret-registry-plugin</artifactId>
                <version>${io.confluent.secret-registry.version}</version>
            </dependency>

            <dependency>
                <groupId>javax.xml.ws</groupId>
                <artifactId>jaxws-api</artifactId>
                <version>2.3.0</version>
            </dependency>
            <dependency>
                <groupId>com.google.guava</groupId>
                <artifactId>guava</artifactId>
                <version>${guava.version}</version>
            </dependency>
        </dependencies>
    </dependencyManagement>

    <build>
        <pluginManagement>
            <plugins>
                <plugin>
                    <groupId>org.codehaus.mojo</groupId>
                    <artifactId>exec-maven-plugin</artifactId>
                    <version>${exec-maven-plugin.version}</version>
                </plugin>
            </plugins>
        </pluginManagement>
        <plugins>
            <plugin>
                <groupId>org.codehaus.mojo</groupId>
                <artifactId>exec-maven-plugin</artifactId>
                <executions>
                    <execution>
                        <goals>
                            <goal>java</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
            <plugin>
                <groupId>com.github.spotbugs</groupId>
                <artifactId>spotbugs-maven-plugin</artifactId>
                <version>${spotbugs.maven.plugin.version}</version>
                <configuration>
                    <xmlOutput>true</xmlOutput>
                    <excludeFilterFile>findbugs/findbugs-exclude.xml</excludeFilterFile>
                    <effort>Max</effort>
                    <threshold>Max</threshold>
                    <failOnError>true</failOnError>
                    <includeTests>false</includeTests>
                </configuration>
                <executions>
                    <!--
                    Ensures that FindBugs inspects source code when project is compiled.
                    -->
                    <execution>
                        <id>analyze-compile</id>
                        <phase>compile</phase>
                        <goals>
                            <goal>check</goal>
                        </goals>
                    </execution>
                </executions>
            </plugin>
        </plugins>
    </build>

    <profiles>
        <profile>
            <id>surefire-failsafe</id>
            <activation>
                <jdk>(1.8,)</jdk>
            </activation>
            <build>
                <plugins>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-surefire-plugin</artifactId>
                        <configuration>
                            <argLine>
                                --add-opens java.base/java.lang=ALL-UNNAMED
                            </argLine>
                        </configuration>
                    </plugin>
                    <plugin>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-failsafe-plugin</artifactId>
                        <configuration>
                            <argLine>
                                --add-opens java.security.jgss/sun.security.krb5=ALL-UNNAMED
                            </argLine>
                        </configuration>
                    </plugin>
                </plugins>
            </build>
        </profile>
    </profiles>
</project>
