<?xml version="1.0" encoding="UTF-8"?>
<!--
 Copyright © 2017 Red Hat, Inc. and others. All rights reserved.

 This program and the accompanying materials are made available under the
 terms of the Eclipse Public License v1.0 which accompanies this distribution,
 and is available at http://www.eclipse.org/legal/epl-v10.html
-->
<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.opendaylight.infrautils</groupId>
    <artifactId>parent</artifactId>
    <version>1.4.0</version>
    <relativePath>../../..//infrautils/common/parent</relativePath>
  </parent>

  <artifactId>metrics-impl</artifactId>
  <packaging>bundle</packaging>
  <!-- <name> formatting is used by autorelease to parse and notify projects on
       build failure. Please do not modify this unless you have a good reason. -->
  <name>ODL :: infrautils :: ${project.artifactId}</name>

  <dependencies>
    <dependency>
      <groupId>org.opendaylight.infrautils</groupId>
      <artifactId>metrics-api</artifactId>
      <version>${project.version}</version>
    </dependency>

    <dependency>
      <groupId>io.dropwizard.metrics</groupId>
      <artifactId>metrics-core</artifactId>
      <!-- This version must be kept in line with the ones used below -->
      <version>4.0.2</version>
    </dependency>
    <dependency>
      <groupId>io.dropwizard.metrics</groupId>
      <artifactId>metrics-jmx</artifactId>
      <!-- This version must be kept in line with the ones used above -->
      <version>4.0.2</version>
    </dependency>
    <dependency>
      <groupId>io.dropwizard.metrics</groupId>
      <artifactId>metrics-jvm</artifactId>
      <!-- This version must be kept in line with the ones used above -->
      <version>4.0.2</version>
    </dependency>
<!-- TODO
    <dependency>
      <groupId>io.dropwizard.metrics</groupId>
      <artifactId>metrics-log4j2</artifactId>
      <!- - This version must be kept in line with the ones used above - ->
      <version>4.0.2</version>
    </dependency>
 -->
    <dependency>
      <groupId>org.opendaylight.infrautils</groupId>
      <artifactId>infrautils-util</artifactId>
      <version>${project.version}</version>
    </dependency>
    <dependency>
      <groupId>javax.inject</groupId>
      <artifactId>javax.inject</artifactId>
    </dependency>
    <dependency>
      <groupId>org.ops4j.pax.cdi</groupId>
      <artifactId>pax-cdi-api</artifactId>
      <optional>true</optional>
    </dependency>

    <dependency>
      <groupId>org.opendaylight.infrautils</groupId>
      <artifactId>infrautils-testutils</artifactId>
      <version>${project.version}</version>
      <scope>test</scope>
    </dependency>
  </dependencies>

  <build>
    <plugins>
      <plugin>
        <groupId>org.apache.aries.blueprint</groupId>
        <artifactId>blueprint-maven-plugin</artifactId>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>build-helper-maven-plugin</artifactId>
        <executions>
          <execution>
            <id>attach-artifacts</id>
            <goals>
              <goal>attach-artifact</goal>
            </goals>
            <phase>package</phase>
            <configuration>
              <artifacts>
                <artifact>
                  <file>${project.build.directory}/classes/etc/org.opendaylight.infrautils.metrics.cfg</file>
                  <type>cfg</type>
                  <classifier>config</classifier>
                </artifact>
              </artifacts>
              <packaging>jar</packaging>
            </configuration>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>
</project>
