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

    JBoss, Home of Professional Open Source.
    Copyright 2014-2020 Red Hat, Inc., and individual 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.bom</groupId> <!-- Use BOM as parent to have access to the properties -->
    <artifactId>jboss-eap-jakartaee8</artifactId>
    <version>7.3.1.GA</version>
  </parent>

  <groupId>org.jboss.pnc</groupId>
  <artifactId>parent</artifactId>
  <version>2.2.2</version>
  <packaging>pom</packaging>

  <name>pnc</name>
  <description>A system for managing, executing, and tracking builds.</description>
  <url>https://github.com/project-ncl</url>
  <inceptionYear>2014</inceptionYear>

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

  <scm>
    <connection>scm:git:https://github.com/project-ncl/pnc.git</connection>
    <developerConnection>scm:git:git@github.com:project-ncl/pnc.git</developerConnection>
    <url>https://github.com/project-ncl/pnc/</url>
    <tag>2.2.2.RC1</tag>
  </scm>

  <developers>
    <developer>
      <organization>RedHat</organization>
      <organizationUrl>http://www.redhat.com</organizationUrl>
    </developer>
  </developers>

  <modules>
    <module>constants</module>
    <module>test-common</module>
    <module>common</module>
    <module>causeway-client</module>
    <module>moduleconfig</module>
    <module>auth</module>
    <module>datastore</module>
    <module>messaging-spi</module>
    <module>messaging</module>
    <module>ear-package</module>
    <module>termd-build-driver</module>
    <module>indy-repository-manager</module>
    <module>build-coordinator</module>
    <module>build-executor</module>
    <module>model</module>
    <module>dto</module>
    <module>facade</module>
    <module>rest-api</module>
    <module>rest</module>
    <module>notifications</module>
    <module>spi</module>
    <module>web</module>
    <module>openshift-environment-driver</module>
    <module>demo-data</module>
    <module>integration-test</module>
    <module>pnc-mock</module> <!-- keep 'pnc' prefix as 'mock' is dy default ignored in some cases (intellij) -->
    <module>bpm</module>
    <module>processor</module>
    <module>rest-client</module>
    <module>mapper</module>
    <module>bpm-mock</module>
  </modules>

  <properties>
    <!-- minimum jdk and maven versions -->
    <jdk.min.version>1.8</jdk.min.version>
    <maven.compiler.source>1.8</maven.compiler.source>
    <maven.compiler.target>1.8</maven.compiler.target>
    <maven.min.version>3.2</maven.min.version>
    <!--<version.org.jboss.spec.javax.jms.jboss-jms-api_2.0_spec>1.0.2.Final-redhat-1</version.org.jboss.spec.javax.jms.jboss-jms-api_2.0_spec>-->
    <version.org.jboss.spec.javax.jms.jboss-jms-api_1.1_spec>1.0.1.Final</version.org.jboss.spec.javax.jms.jboss-jms-api_1.1_spec>
    <atlasVersion>1.1.0</atlasVersion>
    <indyVersion>2.5.4</indyVersion>
    <version.assertj-core>3.18.1</version.assertj-core>
    <version.mockito>3.8.0</version.mockito>
    <version.catch-exception>1.2.0</version.catch-exception>
    <version.jbpm>6.2.0.Final</version.jbpm>
    <version.kie-services-client>6.5.0.Final</version.kie-services-client>
    <version.keycloak>9.0.3.redhat-00002</version.keycloak>
    <version.shrinkwrap.descriptors>2.0.0</version.shrinkwrap.descriptors>
    <version.swagger2>2.1.4</version.swagger2>
    <version.buildagent>1.0.0</version.buildagent>
    <version.lombok>1.18.18</version.lombok>
    <version.mapstruct>1.4.2.Final</version.mapstruct>
    <version.junit>4.13.1</version.junit>
    <version.org.glassfish.javax.el-impl>3.0.1.b08-redhat-1</version.org.glassfish.javax.el-impl>
    <version.vertx.core>3.8.5</version.vertx.core>
    <version.pnc-api>2.2.0</version.pnc-api>
    <version.pnc-common>2.1.0</version.pnc-common>
    <!-- same base version (no -redhat) as version.org.apache.httpcomponents.httpclient from the eap BOM-->
    <version.org.apache.httpcomponents.fluent-hc>4.5.4</version.org.apache.httpcomponents.fluent-hc>

    <!-- -redhat version is missing some packages -->
    <version.com.github.fge>1.9</version.com.github.fge>

    <!-- Package URL -->
    <version.com.github.package-url>1.3.1</version.com.github.package-url>

    <datetime>${timestamp}</datetime>
    <pushChanges>true</pushChanges>

    <illegaltransitivereportonly>false</illegaltransitivereportonly>

    <!-- Default DB for NCL is HSQLDB -->
    <persistence.jta-data-source>java:jboss/datasources/NewcastleTestDS</persistence.jta-data-source>
    <!--<persistence.hibernate.dialect>org.hibernate.dialect.HSQLDialect</persistence.hibernate.dialect>-->
    <persistence.hibernate.hbm2ddl.auto>create-drop</persistence.hibernate.hbm2ddl.auto>

    <!-- Jacoco & Sonar -->
    <sonar.jacoco.reportPath>${project.basedir}/target/jacoco-unit.exec</sonar.jacoco.reportPath>
    <sonar.jacoco.itReportPath>${project.basedir}/../target/jacoco-it.exec</sonar.jacoco.itReportPath>
    <itCoverageAgent />

    <!-- Integration tests -->
    <app.server>jboss-eap</app.server>
    <jboss.version>7.3</jboss.version>
    <default.management.port>9999</default.management.port>
    <test.server.unpack.dir>${project.basedir}/target</test.server.unpack.dir>
    <test.server.build.dir>${test.server.unpack.dir}/${app.server}-${jboss.version}</test.server.build.dir>
    <arquillian.container.type>managed</arquillian.container.type>
    <jboss.port.offset>0</jboss.port.offset>
    <jboss.management.port>${default.management.port}</jboss.management.port>
    <surefire.test.remote.skip>true</surefire.test.remote.skip>
    <auth>false</auth>
    <tagSuffix />
  </properties>

  <dependencies>
    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-api</artifactId>
    </dependency>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.mockito</groupId>
      <artifactId>mockito-core</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.assertj</groupId>
      <artifactId>assertj-core</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>ch.qos.logback</groupId>
      <artifactId>logback-classic</artifactId>
      <scope>test</scope>
    </dependency>
  </dependencies>


  <dependencyManagement>
    <dependencies>

      <!-- BOMs -->
      <dependency>
        <groupId>org.jboss.arquillian.extension</groupId>
        <artifactId>arquillian-transaction-bom</artifactId>
        <version>1.0.5</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
      <dependency>
        <groupId>org.jboss.shrinkwrap.resolver</groupId>
        <artifactId>shrinkwrap-resolver-bom</artifactId>
        <version>3.1.4</version>
        <scope>import</scope>
        <type>pom</type>
      </dependency>
      <dependency>
        <groupId>org.jboss.arquillian</groupId>
        <artifactId>arquillian-bom</artifactId>
        <version>1.6.0.Final</version>
        <type>pom</type>
        <scope>import</scope>
      </dependency>
      <dependency>
        <groupId>com.redhat.bom.rh-sso</groupId>
        <artifactId>rh-sso-adapter-bom</artifactId>
        <version>7.4.0.GA</version> <!-- If you are changing this, change also version.keycloak!-->
        <type>pom</type>
        <scope>import</scope>
      </dependency>

      <!-- provided dependencies -->
      <dependency>
        <groupId>com.fasterxml.jackson.core</groupId>
        <artifactId>jackson-core</artifactId>
        <version>${version.com.fasterxml.jackson.core}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>com.fasterxml.jackson.core</groupId>
        <artifactId>jackson-databind</artifactId>
        <version>${version.com.fasterxml.jackson.core}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>com.fasterxml.jackson.core</groupId>
        <artifactId>jackson-annotations</artifactId>
        <version>${version.com.fasterxml.jackson.core}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.codehaus.jackson</groupId>
        <artifactId>jackson-jaxrs</artifactId>
        <version>${version.org.codehaus.jackson}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>com.fasterxml.jackson.jaxrs</groupId>
        <artifactId>jackson-jaxrs-json-provider</artifactId>
        <version>${version.com.fasterxml.jackson.jaxrs}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>com.fasterxml.jackson.jaxrs</groupId>
        <artifactId>jackson-jaxrs-base</artifactId>
        <version>${version.com.fasterxml.jackson.jaxrs}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>com.fasterxml.jackson.module</groupId>
        <artifactId>jackson-module-jaxb-annotations</artifactId>
        <version>${version.com.fasterxml.jackson.module}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.codehaus.jackson</groupId>
        <artifactId>jackson-xc</artifactId>
        <version>${version.org.codehaus.jackson}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>commons-io</groupId>
        <artifactId>commons-io</artifactId>
        <version>${version.commons-io}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>commons-codec</groupId>
        <artifactId>commons-codec</artifactId>
        <version>${version.commons-codec}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.jboss.xnio</groupId>
        <artifactId>xnio-api</artifactId>
        <version>${version.org.jboss.xnio}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.jboss.xnio</groupId>
        <artifactId>xnio-nio</artifactId>
        <version>${version.org.jboss.xnio}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>io.undertow</groupId>
        <artifactId>undertow-core</artifactId>
        <version>${version.io.undertow}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.jboss.logmanager</groupId>
        <artifactId>jboss-logmanager</artifactId>
        <version>${version.org.jboss.logmanager}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>net.jcip</groupId>
        <artifactId>jcip-annotations</artifactId>
        <version>1.0.0.redhat-8</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>com.jcraft</groupId>
        <artifactId>jsch</artifactId>
        <version>${version.com.jcraft.jsch}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.jboss.resteasy</groupId>
        <artifactId>resteasy-jaxrs</artifactId>
        <version>${version.org.jboss.resteasy}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.yaml</groupId>
        <artifactId>snakeyaml</artifactId>
        <version>1.27</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.wildfly.common</groupId>
        <artifactId>wildfly-common</artifactId>
        <version>1.5.1.Final-redhat-00001</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.wildfly.client</groupId>
        <artifactId>wildfly-client-config</artifactId>
        <version>1.0.1.Final-redhat-00001</version>
        <scope>provided</scope>
      </dependency>

      <!-- Project modules, to support cross-module dependencies -->
      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>auth</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>test-common</artifactId>
        <version>${project.version}</version>
        <scope>test</scope>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>constants</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>common</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>causeway-client</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>moduleconfig</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>datastore</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>messaging-spi</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>messaging</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>ear-package</artifactId>
        <version>${project.version}</version>
        <type>ear</type>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>ear-package</artifactId>
        <version>${project.version}</version>
        <type>pom</type>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>indy-repository-manager</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>build-coordinator</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>build-executor</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>pnc-mock</artifactId>
        <version>${project.version}</version>
        <scope>test</scope>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc.metrics</groupId>
        <artifactId>pncmetrics</artifactId>
        <version>1.1.3</version>
        <exclusions>
          <exclusion>
            <groupId>org.jboss.spec.javax.ejb</groupId>
            <artifactId>jboss-ejb-api_3.2_spec</artifactId>
          </exclusion>
          <exclusion>
            <groupId>javax.inject</groupId>
            <artifactId>javax.inject</artifactId>
          </exclusion>
          <exclusion>
            <groupId>javax.annotation</groupId>
            <artifactId>javax.annotation-api</artifactId>
          </exclusion>
          <exclusion>
            <groupId>javax.ws.rs</groupId>
            <artifactId>javax.ws.rs-api</artifactId>
          </exclusion>
          <exclusion>
            <groupId>javax.enterprise</groupId>
            <artifactId>cdi-api</artifactId>
          </exclusion>
        </exclusions>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>model</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>dto</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>dto</artifactId>
        <classifier>patch-builders</classifier>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>mapper</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>facade</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>rest-api</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>rest-api</artifactId>
        <classifier>java-client</classifier>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>rest-client</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>rest</artifactId>
        <version>${project.version}</version>
        <type>war</type>
      </dependency>

      <!-- Use this dependency to attach war classes -->
      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>rest</artifactId>
        <version>${project.version}</version>
        <classifier>classes</classifier>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>notifications</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>bpm</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>bpm-mock</artifactId>
        <version>${project.version}</version>
        <scope>test</scope>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>processor</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>termd-build-driver</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>spi</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>web</artifactId>
        <version>${project.version}</version>
        <type>war</type>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>openshift-environment-driver</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>integration-test</artifactId>
        <version>${project.version}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>demo-data</artifactId>
        <version>${project.version}</version>
      </dependency>
      <!-- END: Project modules -->

      <dependency>
        <groupId>org.jboss.pnc.build-agent</groupId>
        <artifactId>api</artifactId>
        <version>${version.buildagent}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc.build-agent</groupId>
        <artifactId>client</artifactId>
        <version>${version.buildagent}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.pnc.build-agent</groupId>
        <artifactId>server</artifactId>
        <version>${version.buildagent}</version>
      </dependency>


      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>pnc-api</artifactId>
        <version>${version.pnc-api}</version>
      </dependency>
      <dependency>
        <groupId>org.jboss.pnc</groupId>
        <artifactId>pnc-common</artifactId>
        <version>${version.pnc-common}</version>
      </dependency>

      <!-- We need to have these keycloaks here becasue they are not provided
           by the BOM and are needed by indy-embedder dependency -->
      <dependency>
        <groupId>org.keycloak</groupId>
        <artifactId>keycloak-common</artifactId>
        <version>${version.keycloak}</version>
      </dependency>
      <dependency>
        <groupId>org.keycloak</groupId>
        <artifactId>keycloak-undertow-adapter-spi</artifactId>
        <version>${version.keycloak}</version>
      </dependency>
      <dependency>
        <groupId>org.jboss.spec.javax.jms</groupId>
        <artifactId>jboss-jms-api_1.1_spec</artifactId>
        <version>${version.org.jboss.spec.javax.jms.jboss-jms-api_1.1_spec}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.hibernate.orm.tooling</groupId>
        <artifactId>hibernate-enhance-maven-plugin</artifactId>
        <version>${version.org.hibernate.hibernate-core}</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.shrinkwrap.descriptors</groupId>
        <artifactId>shrinkwrap-descriptors-impl-javaee</artifactId>
        <version>${version.shrinkwrap.descriptors}</version>
      </dependency>

      <dependency>
        <groupId>io.swagger.core.v3</groupId>
        <artifactId>swagger-jaxrs2</artifactId>
        <version>${version.swagger2}</version>
      </dependency>

      <dependency>
        <groupId>io.swagger.core.v3</groupId>
        <artifactId>swagger-annotations</artifactId>
        <version>${version.swagger2}</version>
      </dependency>

      <dependency>
        <groupId>org.glassfish</groupId>
        <artifactId>javax.el-impl</artifactId>
        <version>${version.org.glassfish.javax.el-impl}</version>
        <scope>test</scope>
        <exclusions>
          <exclusion> <!-- using jboss-el-api -->
            <groupId>org.glassfish</groupId>
            <artifactId>javax.el-api</artifactId>
          </exclusion>
        </exclusions>
      </dependency>
      <dependency> <!-- required by indy-repository-manager tests -->
        <groupId>org.glassfish.web</groupId>
        <artifactId>javax.el</artifactId>
        <version>2.2.6</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.jsoup</groupId>
        <artifactId>jsoup</artifactId>
        <version>1.8.3</version> <!-- version required by indy-repository-manager tests -->
        <scope>test</scope>
      </dependency>

      <dependency>
        <groupId>org.apache.httpcomponents</groupId>
        <artifactId>fluent-hc</artifactId>
        <version>${version.org.apache.httpcomponents.fluent-hc}</version>
      </dependency>

      <dependency>
        <groupId>org.commonjava.atlas</groupId>
        <artifactId>atlas-identities</artifactId>
        <version>${atlasVersion}</version>
        <exclusions>
          <exclusion>
            <groupId>ch.qos.logback</groupId>
            <artifactId>logback-classic</artifactId>
          </exclusion>
        </exclusions>
      </dependency>
      <dependency>
        <groupId>org.commonjava.atlas</groupId>
        <artifactId>atlas-npm-identities</artifactId>
        <version>${atlasVersion}</version>
        <exclusions>
          <exclusion>
            <groupId>ch.qos.logback</groupId>
            <artifactId>logback-classic</artifactId>
          </exclusion>
        </exclusions>
      </dependency>

      <dependency>
        <groupId>io.undertow</groupId>
        <artifactId>undertow-websockets-jsr</artifactId>
        <version>${version.io.undertow}</version>
        <scope>provided</scope>
      </dependency>

      <dependency>
        <groupId>org.jboss</groupId>
        <artifactId>jboss-common-core</artifactId>
        <version>2.5.0.Final</version>
      </dependency>

      <dependency>
        <groupId>org.jboss.arquillian.container</groupId>
        <artifactId>arquillian-weld-se-embedded-1.1</artifactId>
        <version>1.0.0.Final</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.wildfly.arquillian</groupId>
        <artifactId>wildfly-arquillian-container-managed</artifactId>
        <version>3.0.1.Final</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.jboss.arquillian.extension</groupId>
        <artifactId>arquillian-jacoco</artifactId>
        <version>1.1.0</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>com.github.tomakehurst</groupId>
        <artifactId>wiremock-jre8</artifactId>
        <version>2.27.2</version>
        <scope>test</scope>
      </dependency>

      <dependency>
        <groupId>org.jboss.weld</groupId>
        <artifactId>weld-core-impl</artifactId>
        <version>3.1.4.Final</version>
      </dependency>

      <dependency>
        <groupId>ch.qos.logback</groupId>
        <artifactId>logback-classic</artifactId>
        <version>1.2.3</version>
      </dependency>

      <dependency>
        <groupId>org.springframework.data</groupId>
        <artifactId>spring-data-jpa</artifactId>
        <version>1.11.23.RELEASE</version>
      </dependency>

      <dependency>
        <groupId>org.springframework.data</groupId>
        <artifactId>spring-data-commons</artifactId>
        <version>1.13.23.RELEASE</version>
      </dependency>

      <!-- retries for completable futures -->
      <dependency>
        <groupId>net.jodah</groupId>
        <artifactId>failsafe</artifactId>
        <version>2.4.0</version>
      </dependency>

      <dependency>
        <groupId>io.fabric8</groupId>
        <artifactId>openshift-client</artifactId>
        <version>5.0.1</version>
      </dependency>

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

      <dependency>
        <groupId>org.kie.remote</groupId>
        <artifactId>kie-remote-client</artifactId>
        <version>${version.kie-services-client}</version>
        <exclusions>
          <exclusion>
            <groupId>org.apache.cxf</groupId>
            <artifactId>cxf-api</artifactId>
          </exclusion>
          <exclusion>
            <groupId>org.apache.cxf</groupId>
            <artifactId>cxf-rt-transports-http</artifactId>
          </exclusion>
          <exclusion>
            <groupId>org.apache.cxf</groupId>
            <artifactId>cxf-rt-frontend-simple</artifactId>
          </exclusion>
          <exclusion>
            <groupId>org.apache.cxf</groupId>
            <artifactId>cxf-rt-frontend-jaxws</artifactId>
          </exclusion>
          <exclusion>
            <groupId>org.apache.cxf</groupId>
            <artifactId>cxf-rt-databinding-jaxb</artifactId>
          </exclusion>
          <exclusion>
            <groupId>org.hornetq</groupId>
            <artifactId>hornetq-core-client</artifactId>
          </exclusion>
          <exclusion>
            <groupId>org.codehaus.jackson</groupId>
            <artifactId>jackson-mapper-asl</artifactId>
          </exclusion>
          <exclusion>
            <groupId>org.codehaus.jackson</groupId>
            <artifactId>jackson-core-asl</artifactId>
          </exclusion>
          <exclusion>
            <groupId>com.sun.xml.bind</groupId>
            <artifactId>jaxb-core</artifactId>
          </exclusion>
          <exclusion>
            <groupId>com.sun.xml.bind</groupId>
            <artifactId>jaxb-impl</artifactId>
          </exclusion>
        </exclusions>
      </dependency>

      <dependency>
        <groupId>org.projectlombok</groupId>
        <artifactId>lombok</artifactId>
        <version>${version.lombok}</version>
        <scope>provided</scope>
      </dependency>


      <dependency>
          <groupId>org.mapstruct</groupId>
          <artifactId>mapstruct</artifactId>
          <version>${version.mapstruct}</version>
      </dependency>

      <dependency>
          <groupId>com.github.package-url</groupId>
          <artifactId>packageurl-java</artifactId>
          <version>${version.com.github.package-url}</version>
      </dependency>

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

      <dependency>
        <groupId>org.dbunit</groupId>
        <artifactId>dbunit</artifactId>
        <version>2.7.0</version>
        <scope>test</scope>
      </dependency>

      <dependency>
        <groupId>org.jboss.weld.se</groupId>
        <artifactId>weld-se</artifactId>
        <version>2.4.8.Final</version>
        <scope>test</scope>
      </dependency>

      <dependency>
        <groupId>org.jacoco</groupId>
        <artifactId>org.jacoco.core</artifactId>
        <version>0.8.6</version>
      </dependency>

      <dependency>
        <groupId>org.assertj</groupId>
        <artifactId>assertj-core</artifactId>
        <version>${version.assertj-core}</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.mockito</groupId>
        <artifactId>mockito-core</artifactId>
        <version>${version.mockito}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>net.bytebuddy</groupId>
        <artifactId>byte-buddy</artifactId>
        <version>1.10.18</version> <!-- force version provided by mockito to override hibernate version -->
      </dependency>
      <dependency>
        <groupId>com.googlecode.catch-exception</groupId>
        <artifactId>catch-exception</artifactId>
        <version>${version.catch-exception}</version>
        <scope>test</scope>
      </dependency>
      <dependency>
        <groupId>org.slf4j</groupId>
        <artifactId>slf4j-log4j12</artifactId>
        <version>1.7.30</version>
        <scope>test</scope>
      </dependency>

      <dependency>
        <groupId>org.commonjava.indy</groupId>
        <artifactId>indy-model-core-java</artifactId>
        <version>${indyVersion}</version>
      </dependency>
      <dependency>
        <groupId>org.commonjava.indy</groupId>
        <artifactId>indy-promote-client-java</artifactId>
        <version>${indyVersion}</version>
        <exclusions>
          <exclusion>
            <groupId>ch.qos.logback</groupId>
            <artifactId>logback-classic</artifactId>
          </exclusion>
        </exclusions>
      </dependency>
      <dependency>
        <groupId>org.commonjava.indy</groupId>
        <artifactId>indy-folo-client-java</artifactId>
        <version>${indyVersion}</version>
        <exclusions>
          <exclusion>
            <groupId>ch.qos.logback</groupId>
            <artifactId>logback-classic</artifactId>
          </exclusion>
        </exclusions>
      </dependency>
      <dependency>
        <groupId>org.commonjava.indy</groupId>
        <artifactId>indy-client-core-java</artifactId>
        <version>${indyVersion}</version>
        <exclusions>
          <exclusion>
            <groupId>ch.qos.logback</groupId>
            <artifactId>logback-classic</artifactId>
          </exclusion>
        </exclusions>
      </dependency>
      <dependency>
        <groupId>org.commonjava.indy.embed</groupId>
        <artifactId>indy-embedder</artifactId>
        <version>${indyVersion}</version>
        <scope>test</scope>
        <exclusions>
          <exclusion>
            <groupId>ch.qos.logback</groupId>
            <artifactId>logback-classic</artifactId>
          </exclusion>
        </exclusions>
      </dependency>
      <dependency>
        <groupId>org.commonjava.indy</groupId>
        <artifactId>indy-test-fixtures-core</artifactId>
        <version>${indyVersion}</version>
        <scope>test</scope>
        <exclusions>
          <exclusion>
            <groupId>org.commonjava.indy.boot</groupId>
            <artifactId>indy-booter-api</artifactId>
          </exclusion>
          <exclusion>
            <groupId>ch.qos.logback</groupId>
            <artifactId>logback-classic</artifactId>
          </exclusion>
        </exclusions>
      </dependency>

      <dependency>
        <groupId>io.rest-assured</groupId>
        <artifactId>rest-assured</artifactId>
        <version>4.3.1</version>
        <scope>test</scope>
      </dependency>

      <dependency>
        <groupId>cz.jirutka.rsql</groupId>
        <artifactId>rsql-parser</artifactId>
        <version>2.1.0</version>
      </dependency>

      <dependency>
        <groupId>com.fasterxml.jackson.datatype</groupId>
        <artifactId>jackson-datatype-jdk8</artifactId>
        <version>${version.com.fasterxml.jackson.core}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>com.fasterxml.jackson.datatype</groupId>
        <artifactId>jackson-datatype-jsr310</artifactId>
        <version>${version.com.fasterxml.jackson.core}</version>
        <scope>provided</scope>
      </dependency>

      <dependency>
        <groupId>commons-lang</groupId>
        <artifactId>commons-lang</artifactId>
        <version>2.6</version>
        <scope>provided</scope>
      </dependency>

      <dependency>
        <groupId>commons-beanutils</groupId>
        <artifactId>commons-beanutils</artifactId>
        <version>1.9.4</version>
        <scope>provided</scope>
      </dependency>

      <dependency>
        <groupId>commons-logging</groupId>
        <artifactId>commons-logging</artifactId>
        <version>1.2</version>
        <scope>provided</scope>
      </dependency>

      <dependency>
        <groupId>commons-collections</groupId>
        <artifactId>commons-collections</artifactId>
        <version>3.2.2</version>
        <scope>provided</scope>
      </dependency>

      <dependency>
        <groupId>org.apache.commons</groupId>
        <artifactId>commons-lang3</artifactId>
        <version>3.9</version>
        <scope>provided</scope>
      </dependency>

      <dependency>
        <groupId>org.apache.httpcomponents</groupId>
        <artifactId>httpclient</artifactId>
        <version>${version.org.apache.httpcomponents.httpclient}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.apache.httpcomponents</groupId>
        <artifactId>httpcore</artifactId>
        <version>${version.org.apache.httpcomponents.httpcore}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.jboss.spec.javax.annotation</groupId>
        <artifactId>jboss-annotations-api_1.3_spec</artifactId>
        <version>${version.org.jboss.spec.javax.annotation}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.jboss</groupId>
        <artifactId>jboss-dmr</artifactId>
        <version>${version.org.jboss.jboss-dmr}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.jboss.spec.javax.ejb</groupId>
        <artifactId>jboss-ejb-api_3.2_spec</artifactId>
        <version>${version.org.jboss.spec.javax.ejb}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.jboss.spec.javax.el</groupId>
        <artifactId>jboss-el-api_3.0_spec</artifactId>
        <version>${version.org.jboss.spec.javax.el}</version>
        <scope>provided</scope>
      </dependency>
      <!--dependency>
        <groupId>org.jboss.spec.javax.xml.bind</groupId>
        <artifactId>jboss-jaxb-api_2.3_spec</artifactId>
        <version>${version.org.jboss.spec.javax.xml.bind}</version>
        <scope>provided</scope>
      </dependency-->
      <dependency>
        <groupId>org.jboss.spec.javax.xml.ws</groupId>
        <artifactId>jboss-jaxws-api_2.3_spec</artifactId>
        <version>${version.org.jboss.spec.javax.xml.ws}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.jboss.spec.javax.ws.rs</groupId>
        <artifactId>jboss-jaxrs-api_2.1_spec</artifactId>
        <version>${version.org.jboss.spec.javax.ws.rs}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.jboss.logging</groupId>
        <artifactId>jboss-logging</artifactId>
        <version>${version.org.jboss.logging.jboss-logging}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.jboss.threads</groupId>
        <artifactId>jboss-threads</artifactId>
        <version>${version.org.jboss.threads}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.jboss.spec.javax.transaction</groupId>
        <artifactId>jboss-transaction-api_1.3_spec</artifactId>
        <version>${version.org.jboss.spec.javax.transaction}</version>
        <scope>provided</scope>
      </dependency>
      <dependency>
        <groupId>org.slf4j</groupId>
        <artifactId>slf4j-api</artifactId>
        <version>${version.org.slf4j}</version>
        <scope>provided</scope>
      </dependency>

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

      <dependency>
        <groupId>org.hsqldb</groupId>
        <artifactId>hsqldb</artifactId>
        <version>2.4.1</version>
        <scope>test</scope>
        <classifier>jdk8debug</classifier>
      </dependency>

      <dependency>
        <groupId>commons-validator</groupId>
        <artifactId>commons-validator</artifactId>
        <version>1.7</version>
      </dependency>
      <dependency>
        <groupId>com.squareup</groupId>
        <artifactId>javapoet</artifactId>
        <version>1.13.0</version>
      </dependency>

      <dependency>
        <groupId>jakarta.xml.bind</groupId>
        <artifactId>jakarta.xml.bind-api</artifactId>
        <version>2.3.3</version>
        <scope>provided</scope>
      </dependency>

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

      <!-- Second level cache required for tests -->
      <dependency>
        <groupId>org.infinispan</groupId>
        <artifactId>infinispan-hibernate-cache-v53</artifactId>
        <version>${version.org.infinispan}</version>
      </dependency>

      <dependency>
        <groupId>com.github.fge</groupId>
        <artifactId>json-patch</artifactId>
        <version>${version.com.github.fge}</version>
      </dependency>
    </dependencies>
  </dependencyManagement>

  <build>
    <testResources>
      <testResource>
        <directory>src/test/resources</directory>
        <filtering>true</filtering>
      </testResource>
    </testResources>
    <pluginManagement>
      <plugins>
        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>sonar-maven-plugin</artifactId>
          <version>2.7.1</version>
        </plugin>

        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-enforcer-plugin</artifactId>
          <version>1.4.1</version>
          <dependencies>
            <dependency>
              <groupId>org.commonjava.maven.enforcer</groupId>
              <artifactId>enforce-managed-deps-rule</artifactId>
              <version>1.3</version>
            </dependency>
          </dependencies>
          <executions>
            <execution>
              <id>enforce-plugin-versions</id>
              <goals>
                <goal>enforce</goal>
              </goals>
              <configuration>
                <rules>
                  <requirePluginVersions />
                </rules>
              </configuration>
            </execution>

            <execution>
              <id>no-managed-deps</id>
              <goals>
                <goal>enforce</goal>
              </goals>
              <phase>initialize</phase>
              <configuration>
                <rules>
                  <requireManagedDeps implementation="org.commonjava.maven.enforcer.rule.EnforceManagedDepsRule">
                    <checkProfiles>true</checkProfiles>
                    <failOnViolation>true</failOnViolation>
                    <regexIgnored>
                        <regexIgnored>[{]</regexIgnored>
                    </regexIgnored>
                  </requireManagedDeps>
                </rules>
              </configuration>
            </execution>

          </executions>
        </plugin>

        <plugin>
          <artifactId>maven-ear-plugin</artifactId>
          <version>${version.ear.plugin}</version>
          <configuration>
            <version>7</version>
            <defaultLibBundleDir>lib</defaultLibBundleDir>
            <outputFileNameMapping>@{artifactId}@.@{extension}@</outputFileNameMapping>
          </configuration>
        </plugin>

        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>buildnumber-maven-plugin</artifactId>
          <version>${version.buildnumber.plugin}</version>
          <executions>
            <execution>
              <phase>validate</phase>
              <id>buildnumber</id>
              <goals>
                <goal>create</goal>
              </goals>
              <configuration>
                <shortRevisionLength>8</shortRevisionLength>
                <timestampFormat>{0,date,dd MMMM yyyy}</timestampFormat>
              </configuration>
            </execution>
          </executions>
        </plugin>

        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>build-helper-maven-plugin</artifactId>
          <version>${version.buildhelper.plugin}</version>
          <executions>
            <execution>
              <id>parse-version</id>
              <goals>
                <goal>parse-version</goal>
              </goals>
            </execution>
          </executions>
        </plugin>
<!--todo look into using help plugin -->
        <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>properties-maven-plugin</artifactId>
          <version>1.0.0</version>
        </plugin>

        <plugin>
          <groupId>org.codehaus.gmavenplus</groupId>
          <artifactId>gmavenplus-plugin</artifactId>
          <version>1.12.1</version>
          <executions>
            <execution>
              <id>calculate-jboss-port-offset</id>
              <goals>
                <goal>execute</goal>
              </goals>
              <phase>validate</phase>
              <configuration>
                <scripts>
                  <script>
                    offset = Integer.valueOf(System.getProperty("jboss.port.offset",
                    "0"))
                    manPort =
                    Integer.valueOf(project.properties["default.management.port"])
                    project.properties['jboss.management.port'] =
                    "${manPort + offset}".trim()
                  </script>
                </scripts>
              </configuration>
            </execution>
          </executions>
          <dependencies>
            <dependency>
              <groupId>org.codehaus.groovy</groupId>
              <artifactId>groovy-all</artifactId>
              <version>2.4.21</version>
              <scope>runtime</scope>
            </dependency>
          </dependencies>
        </plugin>

        <plugin>
          <groupId>org.wildfly.plugins</groupId>
          <artifactId>wildfly-maven-plugin</artifactId>
          <version>1.2.0.Final</version>
        </plugin>

        <plugin>
          <groupId>org.jacoco</groupId>
          <artifactId>jacoco-maven-plugin</artifactId>
          <version>0.8.6</version>
        </plugin>

        <plugin>
          <groupId>org.jolokia</groupId>
          <artifactId>docker-maven-plugin</artifactId>
          <version>0.13.9</version>
        </plugin>

        <plugin>
          <groupId>org.commonjava.maven.plugins</groupId>
          <artifactId>directory-maven-plugin</artifactId>
          <version>0.3.1</version>
        </plugin>

        <plugin>
          <groupId>com.mycila</groupId>
          <artifactId>license-maven-plugin</artifactId>
          <version>2.11</version>
          <configuration>
            <properties>
              <copyright-years>${project.inceptionYear}-2020</copyright-years>
            </properties>
            <header>${executionRoot}/.license-header.txt</header>
            <excludes>
              <exclude>**/README</exclude>
              <exclude>**/LICENSE.txt</exclude>
              <exclude>**/eclipse-codeStyle.xml</exclude>
              <exclude>.license-header.txt</exclude>
              <exclude>**/plugins.txt</exclude>
              <exclude>**/Dockerfile</exclude>
              <exclude>**/nbactions.xml</exclude>

              <!-- Exclude downloaded/generated -->
              <exclude>**/.cache/**</exclude>
              <exclude>**/rest-config.json</exclude>
            </excludes>
          </configuration>
        </plugin>

        <!--This plugin's configuration is used to store Eclipse m2e settings only. It has no influence on the Maven build itself.-->
        <plugin>
          <groupId>org.eclipse.m2e</groupId>
          <artifactId>lifecycle-mapping</artifactId>
          <version>1.0.0</version>
          <configuration>
            <lifecycleMappingMetadata>
              <pluginExecutions>
                <pluginExecution>
                  <pluginExecutionFilter>
                    <groupId>org.commonjava.maven.plugins</groupId>
                    <artifactId>directory-maven-plugin</artifactId>
                    <versionRange>[0.1,)</versionRange>
                    <goals>
                      <goal>highest-basedir</goal>
                    </goals>
                  </pluginExecutionFilter>
                  <action>
                    <ignore />
                  </action>
                </pluginExecution>
              </pluginExecutions>
            </lifecycleMappingMetadata>
          </configuration>
        </plugin>

        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-gpg-plugin</artifactId>
          <version>1.6</version>
          <executions>
            <execution>
              <id>sign-artifacts</id>
              <phase>verify</phase>
              <goals>
                <goal>sign</goal>
              </goals>
            </execution>
          </executions>
        </plugin>

        <plugin>
          <groupId>org.sonatype.plugins</groupId>
          <artifactId>nexus-staging-maven-plugin</artifactId>
          <version>1.6.8</version>
          <extensions>true</extensions>
          <configuration>
            <serverId>ossrh</serverId>
            <nexusUrl>https://oss.sonatype.org/</nexusUrl>
            <autoReleaseAfterClose>false</autoReleaseAfterClose>
          </configuration>
        </plugin>

        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-compiler-plugin</artifactId>
          <version>3.8.1</version>
<!--TODO works only with J11 -->
<!--      <configuration>-->
<!--            <release>8</release>-->
<!--          </configuration>-->
        </plugin>
        <plugin>
          <!--
          Override the javadoc-plugin version and use the configuraiton from jboss-parent:35.
          Version override is required to avoid: [ERROR] Error fetching link: .../target/apidocs/package-list. Ignored it.
          -->
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-javadoc-plugin</artifactId>
          <version>3.2.0</version>
          <configuration>
            <header><![CDATA[<b>${project.name} ${project.version}</b>]]></header>
            <footer><![CDATA[<b>${project.name} ${project.version}</b>]]></footer>
            <archive>
              <index>true</index>
              <manifest>
                <addDefaultSpecificationEntries>
                  true
                </addDefaultSpecificationEntries>
                <addDefaultImplementationEntries>
                  true
                </addDefaultImplementationEntries>
              </manifest>
              <manifestEntries>
                <Implementation-URL>${project.url}</Implementation-URL>
                <Java-Version>${java.version}</Java-Version>
                <Java-Vendor>${java.vendor}</Java-Vendor>
                <Os-Name>${os.name}</Os-Name>
                <Os-Arch>${os.arch}</Os-Arch>
                <Os-Version>${os.version}</Os-Version>
                <Scm-Url>${project.scm.url}</Scm-Url>
                <Scm-Connection>${project.scm.connection}</Scm-Connection>
                <Scm-Revision>${buildNumber}</Scm-Revision>
              </manifestEntries>
            </archive>
            <additionalOptions>${javadoc.additional.params}</additionalOptions>
          </configuration>
        </plugin>
      </plugins>
    </pluginManagement>

    <plugins>
      <plugin>
        <!--
          Generated javaagent line if often included in some test via filtering. This is why it needs to be executed
          before actual filtering occurs
        -->
        <groupId>org.jacoco</groupId>
        <artifactId>jacoco-maven-plugin</artifactId>
        <executions>
          <execution>
            <id>prepare-unit-tests</id>
            <goals>
              <goal>prepare-agent</goal>
            </goals>
            <phase>generate-resources</phase>
            <configuration>
              <destFile>${sonar.jacoco.reportPath}</destFile>
              <includes>
                <include>org.jboss.pnc.*</include>
              </includes>
            </configuration>
          </execution>
          <execution>
            <id>prepare-integration-tests</id>
            <goals>
              <goal>prepare-agent</goal>
            </goals>
            <phase>generate-resources</phase>
            <configuration>
              <destFile>${sonar.jacoco.itReportPath}</destFile>
              <propertyName>itCoverageAgent</propertyName>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>buildnumber-maven-plugin</artifactId>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>build-helper-maven-plugin</artifactId>
      </plugin>
      <plugin>
          <groupId>org.commonjava.maven.plugins</groupId>
          <artifactId>directory-maven-plugin</artifactId>
          <executions>
              <execution>
                  <id>directories</id>
                  <goals>
                      <goal>highest-basedir</goal>
                  </goals>
                  <phase>validate</phase>
                  <configuration>
                      <property>executionRoot</property>
                  </configuration>
              </execution>
          </executions>
      </plugin>
      <plugin>
          <groupId>org.codehaus.mojo</groupId>
          <artifactId>properties-maven-plugin</artifactId>
          <executions>
              <execution>
                  <phase>validate</phase>
                  <goals>
                      <goal>read-project-properties</goal>
                  </goals>
            <configuration>
              <files>
                <file>${executionRoot}/pnc.cfg</file>
              </files>
              <quiet>true</quiet>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <!-- Check for the minimum version of Java and Maven.  Runs during the validate phase. -->
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-enforcer-plugin</artifactId>
        <executions>
          <execution>
            <id>enforce-java-version</id>
            <goals>
              <goal>enforce</goal>
            </goals>
            <configuration>
              <rules>
                <requireJavaVersion>
                  <message>To build this project JDK ${jdk.min.version} (or greater) is required. Please install it.</message>
                  <version>${jdk.min.version}</version>
                </requireJavaVersion>
              </rules>
            </configuration>
          </execution>
          <execution>
            <id>enforce-maven-version</id>
            <goals>
              <goal>enforce</goal>
            </goals>
            <configuration>
              <rules>
                <requireMavenVersion>
                  <message>To build this project Maven ${maven.min.version} (or greater) is required. Please install it.</message>
                  <version>${maven.min.version}</version>
                </requireMavenVersion>
              </rules>
            </configuration>
          </execution>
        </executions>
      </plugin>
        <plugin>
          <groupId>org.apache.maven.plugins</groupId>
          <artifactId>maven-release-plugin</artifactId>
          <configuration>
            <tagNameFormat>@{project.version}${tagSuffix}</tagNameFormat>
            <autoVersionSubmodules>true</autoVersionSubmodules>
            <useReleaseProfile>false</useReleaseProfile>
            <releaseProfiles>skip-integration-tests,release,production,auth</releaseProfiles>
            <stagingRepository>https://oss.sonatype.org/service/local/staging/deploy/maven2/</stagingRepository>
            <goals>deploy</goals>
          </configuration>
        </plugin>
      <plugin>
        <artifactId>maven-surefire-plugin</artifactId>
        <configuration>
          <argLine>${itCoverageAgent}</argLine>
          <properties>
            <property>
              <name>listener</name>
              <value>org.jboss.pnc.test.listener.PrintTestNameListener</value>
            </property>
          </properties>
          <redirectTestOutputToFile>true</redirectTestOutputToFile>
          <excludedGroups>org.jboss.pnc.test.category.ContainerTest, org.jboss.pnc.test.category.DebugTest</excludedGroups>
          <trimStackTrace>false</trimStackTrace>
        </configuration>
        <executions>
          <execution>
            <id>default-test</id>
            <goals>
              <goal>test</goal>
            </goals>
            <configuration>
              <argLine>${itCoverageAgent}</argLine>
              <!-- To be uncommented when NCL-724 is done -->
              <!--<parallel>all</parallel>-->
              <!--<threadCount>2</threadCount>-->
              <!--<perCoreThreadCount>true</perCoreThreadCount>-->
              <excludedGroups>org.jboss.pnc.test.category.ContainerTest, org.jboss.pnc.test.category.DebugTest</excludedGroups>
              <redirectTestOutputToFile>true</redirectTestOutputToFile>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-antrun-plugin</artifactId>
        <executions>
          <execution>
            <id>IT-required-parameters</id>
            <goals>
              <goal>run</goal>
            </goals>
            <phase>pre-integration-test</phase>
            <configuration>
              <target>
                <condition property="eapZipUrlSatisfied" value="true">
                  <or>
                    <isset property="eap.zip.url" />
                    <!-- are tests disabled ? -->
                    <isset property="skipITs" />
                    <isset property="skipTests" />
                    <equals arg1="${maven.test.skip}" arg2="true" />
                  </or>
                </condition>
                <fail message="You must set the location of the eap zip file 'eap.zip.url'." unless="eapZipUrlSatisfied" />
              </target>
            </configuration>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <artifactId>maven-failsafe-plugin</artifactId>
        <executions>
          <execution>
            <goals>
              <goal>integration-test</goal>
              <goal>verify</goal>
            </goals>
          </execution>
        </executions>
        <configuration>
          <includes>
            <include>**/*.java</include> <!--TODO rename tests to follow the convention. (*IT.java, IT*.java) -->
          </includes>
          <groups>org.jboss.pnc.test.category.ContainerTest</groups>
          <excludedGroups>org.jboss.pnc.test.category.DebugTest</excludedGroups>
          <redirectTestOutputToFile>true</redirectTestOutputToFile>
        </configuration>
      </plugin>
      <plugin>
        <groupId>com.mycila</groupId>
        <artifactId>license-maven-plugin</artifactId>
        <executions>
          <execution>
            <phase>verify</phase>
            <goals>
              <goal>check</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
          <groupId>net.revelc.code.formatter</groupId>
          <artifactId>formatter-maven-plugin</artifactId>
          <version>2.12.2</version>
          <configuration>
              <configFile>../eclipse-codeStyle.xml</configFile>
          </configuration>
          <executions>
              <execution>
                  <id>java-format</id>
                  <goals>
                      <goal>format</goal>
                  </goals>
              </execution>
          </executions>
      </plugin>
    </plugins>
  </build>

  <repositories>

    <repository>
      <id>sonatype-snapshots</id>
      <url>https://oss.sonatype.org/content/repositories/snapshots</url>
      <snapshots>
        <enabled>true</enabled>
      </snapshots>
      <releases>
        <enabled>false</enabled>
      </releases>
    </repository>

    <repository>
      <id>mrrc-ga</id>
      <name>Redhat GA</name>
      <layout>default</layout>
      <url>https://maven.repository.redhat.com/ga/</url>
      <snapshots>
        <enabled>false</enabled>
      </snapshots>
    </repository>

    <repository>
      <id>jboss-snapshots</id>
      <url>https://repository.jboss.org/nexus/content/repositories/snapshots</url>
      <snapshots>
        <enabled>true</enabled>
      </snapshots>
      <releases>
        <enabled>false</enabled>
      </releases>
    </repository>

    <repository>
      <id>Nexus Staging</id>
      <url>https://oss.sonatype.org/content/groups/staging</url>
      <snapshots>
        <enabled>false</enabled>
      </snapshots>
    </repository>
  </repositories>

  <pluginRepositories>
    <pluginRepository>
      <id>mrrc-ga-plugins</id>
      <name>Redhat GA</name>
      <layout>default</layout>
      <url>https://maven.repository.redhat.com/ga/</url>
      <snapshots>
        <enabled>false</enabled>
      </snapshots>
    </pluginRepository>
  </pluginRepositories>

  <profiles>
    <profile>
      <id>debug-tests</id>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-surefire-plugin</artifactId>
            <executions>
              <execution>
                <id>default-test</id>
                <goals>
                  <goal>test</goal>
                </goals>
                <configuration>
                  <groups>org.jboss.pnc.test.category.DebugTest</groups>
                  <excludedGroups>org.jboss.pnc.test.category.ContainerTest</excludedGroups>
                  <test>${test}</test>
                </configuration>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>

    <profile>
      <id>production</id>
      <activation>
        <property>
          <name>production</name>
        </property>
      </activation>
      <properties>
        <persistence.jta-data-source>java:jboss/datasources/NewcastleDS</persistence.jta-data-source>
        <persistence.hibernate.dialect>org.hibernate.dialect.PostgreSQL95Dialect</persistence.hibernate.dialect>
        <persistence.hibernate.hbm2ddl.auto>validate</persistence.hibernate.hbm2ddl.auto>
      </properties>
    </profile>

    <profile>
      <id>devel</id>
      <activation>
        <property>
          <name>devel</name>
        </property>
      </activation>
      <properties>
        <persistence.jta-data-source>java:jboss/datasources/NewcastleDS</persistence.jta-data-source>
        <persistence.hibernate.dialect>org.hibernate.dialect.PostgreSQL95Dialect</persistence.hibernate.dialect>
        <persistence.hibernate.hbm2ddl.auto>update</persistence.hibernate.hbm2ddl.auto>
      </properties>
    </profile>

    <profile>
      <id>license-format</id>
      <build>
        <plugins>
          <plugin>
            <groupId>com.mycila</groupId>
            <artifactId>license-maven-plugin</artifactId>
            <executions>
              <execution>
                <phase>process-sources</phase>
                <goals>
                  <goal>format</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>

    <profile>
      <id>skip-integration-tests</id>
      <properties>
        <skipITs>true</skipITs>
      </properties>
    </profile>
    <profile>
      <id>release</id>
      <build>
        <plugins>
          <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>
            <configuration>
              <source>8</source>
            </configuration>
            <executions>
              <execution>
                <goals>
                  <goal>jar</goal>
                </goals>
                <configuration>
                  <detectOfflineLinks>false</detectOfflineLinks>
                  <quiet>true</quiet>
                  <doclint>none</doclint>
                </configuration>
              </execution>
            </executions>
          </plugin>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-gpg-plugin</artifactId>
          </plugin>
          <plugin>
            <groupId>org.sonatype.plugins</groupId>
            <artifactId>nexus-staging-maven-plugin</artifactId>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>

</project>
