<?xml version="1.0" encoding="UTF-8"?>
<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">
  <parent>
    <artifactId>mutiny-project</artifactId>
    <groupId>io.smallrye.reactive</groupId>
    <version>2.7.0</version>
  </parent>
  <modelVersion>4.0.0</modelVersion>
  <artifactId>mutiny-no-deps</artifactId>
  <name>SmallRye Mutiny - Shaded library</name>
  <description>Variant of Mutiny with shaded dependencies</description>
  <build>
    <plugins>
      <plugin>
        <artifactId>maven-shade-plugin</artifactId>
        <version>${maven-shade-plugin.version}</version>
        <executions>
          <execution>
            <phase>package</phase>
            <goals>
              <goal>shade</goal>
            </goals>
          </execution>
        </executions>
        <configuration>
          <createSourcesJar>true</createSourcesJar>
          <shadeSourcesContent>true</shadeSourcesContent>
          <filters>
            <filter>
              <artifact>*:*</artifact>
              <excludes>
                <exclude>module-info.class</exclude>
                <exclude>META-INF/jandex.idx</exclude>
                <exclude>META-INF/MANIFEST.MF</exclude>
                <exclude>META-INF/maven/**</exclude>
              </excludes>
            </filter>
            <filter>
              <artifact>org.jctools:jctools-core</artifact>
              <includes>
                <include>org/jctools/queues/atomic/unpadded/**</include>
                <include>org/jctools/queues/MessagePassingQueue*</include>
                <include>org/jctools/queues/IndexedQueueSizeUtil*</include>
                <include>org/jctools/queues/QueueProgressIndicators*</include>
                <include>org/jctools/queues/SupportsIterator*</include>
                <include>org/jctools/queues/BaseLinkedQueue*</include>
                <include>org/jctools/queues/LinkedQueueNode*</include>
                <include>org/jctools/queues/atomic/AtomicQueueUtil*</include>
                <include>org/jctools/queues/atomic/AtomicReferenceArrayQueue*</include>
                <include>org/jctools/queues/atomic/SequencedAtomicReferenceArrayQueue*</include>
                <include>org/jctools/queues/atomic/LinkedQueueAtomicNode*</include>
                <include>org/jctools/util/SpscLookAheadUtil*</include>
                <include>org/jctools/util/Pow2*</include>
                <include>org/jctools/util/RangeUtil*</include>
                <include>org/jctools/util/UnsafeAccess*</include>
              </includes>
            </filter>
          </filters>
          <transformers>
            <transformer>
              <manifestEntries />
            </transformer>
          </transformers>
          <relocations>
            <relocation>
              <pattern>org.jctools</pattern>
              <shadedPattern>io.smallrye.mutiny.shaded.org.jctools</shadedPattern>
            </relocation>
            <relocation>
              <pattern>io.smallrye.common</pattern>
              <shadedPattern>io.smallrye.mutiny.shaded.io.smallrye.common</shadedPattern>
            </relocation>
          </relocations>
        </configuration>
      </plugin>
      <plugin>
        <groupId>io.smallrye</groupId>
        <artifactId>jandex-maven-plugin</artifactId>
        <executions>
          <execution>
            <phase>package</phase>
            <goals>
              <goal>jandex-jar</goal>
            </goals>
          </execution>
        </executions>
        <configuration>
          <jar>${project.build.directory}/${project.build.finalName}.jar</jar>
          <includes>
            <include>io/smallrye/mutiny/**/*.class</include>
          </includes>
          <excludes>
            <exclude>io/smallrye/mutiny/shaded/**/*.class</exclude>
          </excludes>
        </configuration>
      </plugin>
      <plugin>
        <groupId>org.cyclonedx</groupId>
        <artifactId>cyclonedx-maven-plugin</artifactId>
      </plugin>
      <plugin>
        <artifactId>maven-failsafe-plugin</artifactId>
        <version>${maven-failsafe-plugin.version}</version>
        <executions>
          <execution>
            <goals>
              <goal>integration-test</goal>
              <goal>verify</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <artifactId>maven-javadoc-plugin</artifactId>
        <configuration>
          <force>true</force>
        </configuration>
      </plugin>
    </plugins>
  </build>
  <dependencies>
    <dependency>
      <groupId>org.junit.jupiter</groupId>
      <artifactId>junit-jupiter-api</artifactId>
      <version>5.11.3</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>opentest4j</artifactId>
          <groupId>org.opentest4j</groupId>
        </exclusion>
        <exclusion>
          <artifactId>junit-platform-commons</artifactId>
          <groupId>org.junit.platform</groupId>
        </exclusion>
        <exclusion>
          <artifactId>apiguardian-api</artifactId>
          <groupId>org.apiguardian</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.junit.jupiter</groupId>
      <artifactId>junit-jupiter-engine</artifactId>
      <version>5.11.3</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>junit-platform-engine</artifactId>
          <groupId>org.junit.platform</groupId>
        </exclusion>
        <exclusion>
          <artifactId>apiguardian-api</artifactId>
          <groupId>org.apiguardian</groupId>
        </exclusion>
      </exclusions>
    </dependency>
  </dependencies>
  <properties>
    <revapi.skip>true</revapi.skip>
  </properties>
</project>
