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

    Copyright 2015-2017 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/xsd/maven-4.0.0.xsd">
  <modelVersion>4.0.0</modelVersion>

  <parent>
    <groupId>org.hawkular.agent</groupId>
    <artifactId>hawkular-wildfly-agent-parent</artifactId>
    <version>0.29.2.Final</version>
  </parent>

  <artifactId>hawkular-wildfly-agent</artifactId>

  <name>Hawkular Agent: WildFly Agent Subsystem</name>
  <description>A WildFly subsystem that is able to collect metrics and send them to Hawkular.</description>

  <dependencies>
    <dependency>
      <groupId>com.fasterxml.jackson.core</groupId>
      <artifactId>jackson-core</artifactId>
      <scope>provided</scope> <!-- this is only provided on later WildFly/EAP versions - EAP 6 is not provided -->
    </dependency>
    <dependency>
      <groupId>com.fasterxml.jackson.core</groupId>
      <artifactId>jackson-databind</artifactId>
      <scope>provided</scope> <!-- this is only provided on later WildFly/EAP versions - EAP 6 is not provided -->
    </dependency>
    <dependency>
      <groupId>com.fasterxml.jackson.core</groupId>
      <artifactId>jackson-annotations</artifactId>
      <scope>provided</scope> <!-- this is only provided on later WildFly/EAP versions - EAP 6 is not provided -->
    </dependency>

    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>org.hawkular.agent</groupId>
      <artifactId>hawkular-agent-core</artifactId>
      <version>${project.version}</version>
    </dependency>

    <dependency>
      <groupId>org.jboss.logging</groupId>
      <artifactId>jboss-logging</artifactId>
      <!-- We need to hardcode this version to ensure that calls like LOG.debugf("x", 1) don't link to
      void debugf(String format, int arg);
      Thus breaking compatibility with EAP6 which doesn't have said method.
      Instead we use 3.1.4.GA to ensure it uses void debugf(String format, Object param1); which is provided
      on both EAP6 and EAP7 see: https://github.com/hawkular/hawkular-agent/pull/271#discussion_r97190787 -->
      <version>3.1.4.GA</version>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.wildfly.core</groupId>
      <artifactId>wildfly-controller</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.wildfly.core</groupId>
      <artifactId>wildfly-controller-client</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.wildfly.core</groupId>
      <artifactId>wildfly-host-controller</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.wildfly</groupId>
      <artifactId>wildfly-naming</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.wildfly.core</groupId>
      <artifactId>wildfly-subsystem-test</artifactId>
      <type>pom</type>
      <scope>test</scope>
    </dependency>

    <!-- these logging dependencies are only compile-time deps for generating log messages -->
    <dependency>
      <groupId>org.jboss.logging</groupId>
      <artifactId>jboss-logging-annotations</artifactId>
      <scope>provided</scope>
      <optional>true</optional>
    </dependency>
    <dependency>
      <groupId>org.jboss.logging</groupId>
      <artifactId>jboss-logging-processor</artifactId>
      <scope>provided</scope>
      <optional>true</optional>
    </dependency>
  </dependencies>

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

</project>
