<?xml version="1.0" encoding="UTF-8"?>
<!--
  ~ Copyright 2024 Red Hat, Inc.
  ~
  ~ Red Hat licenses this file to you 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>io.reactiverse</groupId>
    <artifactId>reactiverse-contextual-logging-parent</artifactId>
    <version>2.0.0.CR1</version>
  </parent>

  <artifactId>reactiverse-contextual-logging-api</artifactId>

  <properties>
    <doc.outputDirectory>${project.build.directory}/generated-docs</doc.outputDirectory>
  </properties>

  <dependencies>
    <dependency>
      <groupId>io.vertx</groupId>
      <artifactId>vertx-core</artifactId>
    </dependency>
    <dependency>
      <groupId>io.vertx</groupId>
      <artifactId>vertx-codegen</artifactId>
      <optional>true</optional>
    </dependency>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>io.vertx</groupId>
      <artifactId>vertx-core</artifactId>
      <type>test-jar</type>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>io.vertx</groupId>
      <artifactId>vertx-web-client</artifactId>
      <scope>test</scope>
    </dependency>
  </dependencies>

  <build>
    <plugins>
      <plugin>
        <artifactId>maven-compiler-plugin</artifactId>
        <configuration>
          <annotationProcessorPaths>
            <annotationProcessorPath>
              <groupId>io.vertx</groupId>
              <artifactId>vertx-codegen</artifactId>
              <version>${vertx.version}</version>
              <classifier>processor</classifier>
            </annotationProcessorPath>
          </annotationProcessorPaths>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.asciidoctor</groupId>
        <artifactId>asciidoctor-maven-plugin</artifactId>
        <version>2.2.6</version>
        <configuration>
          <attributes>
            <group-id>${project.groupId}</group-id>
            <artifact-id>reactiverse-contextual-logging</artifact-id>
            <version>${project.version}</version>
          </attributes>
          <outputDirectory>${doc.outputDirectory}</outputDirectory>
        </configuration>
        <executions>
          <execution>
            <id>output-html</id>
            <phase>generate-resources</phase>
            <goals>
              <goal>process-asciidoc</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <artifactId>maven-jar-plugin</artifactId>
        <configuration>
          <excludes>
            <exclude>examples/**</exclude>
          </excludes>
        </configuration>
        <executions>
          <execution>
            <id>test-jar</id>
            <goals>
              <goal>test-jar</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <artifactId>maven-source-plugin</artifactId>
        <configuration>
          <excludes>
            <exclude>examples/**</exclude>
          </excludes>
        </configuration>
        <executions>
          <execution>
            <id>attach-test-sources</id>
            <goals>
              <goal>test-jar-no-fork</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <artifactId>maven-javadoc-plugin</artifactId>
        <configuration>
          <excludePackageNames>examples</excludePackageNames>
        </configuration>
      </plugin>
    </plugins>
  </build>

</project>
