<!--

    Licensed to the Apache Software Foundation (ASF) under one
    or more contributor license agreements.  See the NOTICE file
    distributed with this work for additional information
    regarding copyright ownership.  The ASF 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/maven-v4_0_0.xsd">
  <modelVersion>4.0.0</modelVersion>

  <parent>
    <groupId>org.apache.pulsar</groupId>
    <artifactId>pulsar</artifactId>
    <version>3.3.5</version>
    <relativePath>../pom.xml</relativePath>
  </parent>

  <artifactId>pulsar-broker</artifactId>
  <packaging>jar</packaging>
  <name>Pulsar Broker</name>

  <dependencies>
    <dependency>
      <groupId>commons-codec</groupId>
      <artifactId>commons-codec</artifactId>
    </dependency>

    <dependency>
      <groupId>org.apache.commons</groupId>
      <artifactId>commons-collections4</artifactId>
    </dependency>

    <dependency>
      <groupId>org.apache.commons</groupId>
      <artifactId>commons-lang3</artifactId>
    </dependency>

    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>slf4j-api</artifactId>
    </dependency>

    <dependency>
      <groupId>io.netty</groupId>
      <artifactId>netty-transport</artifactId>
    </dependency>

    <dependency>
      <groupId>com.google.protobuf</groupId>
      <artifactId>protobuf-java</artifactId>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-client-original</artifactId>
      <version>${project.version}</version>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-websocket</artifactId>
      <version>${project.version}</version>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-client-admin-original</artifactId>
      <version>${project.version}</version>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-cli-utils</artifactId>
      <version>${project.version}</version>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>managed-ledger</artifactId>
      <version>${project.version}</version>
    </dependency>

    <dependency>
      <groupId>org.apache.curator</groupId>
      <artifactId>curator-recipes</artifactId>
    </dependency>

    <dependency>
      <groupId>org.apache.bookkeeper</groupId>
      <artifactId>stream-storage-server</artifactId>
      <exclusions>
        <exclusion>
          <groupId>io.grpc</groupId>
          <artifactId>grpc-all</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.apache.curator</groupId>
          <artifactId>*</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.apache.bookkeeper.tests</groupId>
          <artifactId>stream-storage-tests-common</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.apache.zookeeper</groupId>
          <artifactId>zookeeper</artifactId>
        </exclusion>
        <exclusion>
          <groupId>org.inferred</groupId>
          <artifactId>freebuilder</artifactId>
        </exclusion>
      </exclusions>
    </dependency>

    <dependency>
      <groupId>org.apache.bookkeeper</groupId>
      <artifactId>bookkeeper-tools-framework</artifactId>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-broker-common</artifactId>
      <version>${project.version}</version>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-transaction-common</artifactId>
      <version>${project.version}</version>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-opentelemetry</artifactId>
      <version>${project.version}</version>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-io-batch-discovery-triggerers</artifactId>
      <version>${project.version}</version>
      <scope>test</scope>
    </dependency>

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

    <dependency>
      <groupId>com.github.tomakehurst</groupId>
      <artifactId>wiremock-jre8</artifactId>
      <version>${wiremock.version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>io.github.hakky54</groupId>
      <artifactId>consolecaptor</artifactId>
      <version>${consolecaptor.version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>io.streamnative.oxia</groupId>
      <artifactId>oxia-testcontainers</artifactId>
      <scope>test</scope>
    </dependency>

    <!-- zookeeper server -->
    <dependency>
       <groupId>io.dropwizard.metrics</groupId>
       <artifactId>metrics-core</artifactId>
    </dependency>

    <!-- zookeeper server -->
    <dependency>
       <groupId>org.xerial.snappy</groupId>
       <artifactId>snappy-java</artifactId>
    </dependency>

    <!-- functions related dependencies (begin) -->

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-functions-worker</artifactId>
      <version>${project.version}</version>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-functions-local-runner-original</artifactId>
      <version>${project.version}</version>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-client-messagecrypto-bc</artifactId>
      <version>${project.version}</version>
    </dependency>

    <dependency>
      <groupId>org.awaitility</groupId>
      <artifactId>awaitility</artifactId>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-broker-common</artifactId>
      <version>${project.version}</version>
      <type>test-jar</type>
      <scope>test</scope>
    </dependency>

    <!-- functions related dependencies (end) -->

    <dependency>
      <groupId>org.eclipse.jetty</groupId>
      <artifactId>jetty-server</artifactId>
    </dependency>

    <dependency>
      <groupId>org.eclipse.jetty</groupId>
      <artifactId>jetty-alpn-conscrypt-server</artifactId>
    </dependency>

    <dependency>
      <groupId>org.eclipse.jetty</groupId>
      <artifactId>jetty-servlet</artifactId>
    </dependency>

    <dependency>
      <groupId>org.eclipse.jetty</groupId>
      <artifactId>jetty-servlets</artifactId>
    </dependency>

    <dependency>
      <groupId>org.glassfish.jersey.core</groupId>
      <artifactId>jersey-server</artifactId>
    </dependency>

    <dependency>
      <groupId>org.glassfish.jersey.containers</groupId>
      <artifactId>jersey-container-servlet-core</artifactId>
    </dependency>

    <dependency>
      <groupId>org.glassfish.jersey.containers</groupId>
      <artifactId>jersey-container-servlet</artifactId>
    </dependency>

    <dependency>
      <groupId>org.glassfish.jersey.media</groupId>
      <artifactId>jersey-media-json-jackson</artifactId>
    </dependency>

    <dependency>
      <groupId>org.glassfish.jersey.test-framework</groupId>
      <artifactId>jersey-test-framework-core</artifactId>
      <scope>test</scope>
      <version>${jersey.version}</version>
    </dependency>

    <dependency>
      <groupId>org.glassfish.jersey.test-framework.providers</groupId>
      <artifactId>jersey-test-framework-provider-grizzly2</artifactId>
      <scope>test</scope>
      <version>${jersey.version}</version>
    </dependency>

    <dependency>
      <groupId>jakarta.activation</groupId>
      <artifactId>jakarta.activation-api</artifactId>
    </dependency>

    <dependency>
      <groupId>com.fasterxml.jackson.jaxrs</groupId>
      <artifactId>jackson-jaxrs-json-provider</artifactId>
    </dependency>

    <dependency>
      <groupId>org.glassfish.jersey.inject</groupId>
      <artifactId>jersey-hk2</artifactId>
    </dependency>

    <dependency>
      <groupId>com.fasterxml.jackson.module</groupId>
      <artifactId>jackson-module-jsonSchema</artifactId>
    </dependency>

    <dependency>
      <groupId>org.slf4j</groupId>
      <artifactId>jcl-over-slf4j</artifactId>
    </dependency>

    <dependency>
      <groupId>com.google.guava</groupId>
      <artifactId>guava</artifactId>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-docs-tools</artifactId>
      <version>${project.version}</version>
      <exclusions>
        <exclusion>
          <groupId>io.swagger</groupId>
          <artifactId>*</artifactId>
        </exclusion>
      </exclusions>
    </dependency>

    <dependency>
      <groupId>info.picocli</groupId>
      <artifactId>picocli</artifactId>
    </dependency>

    <dependency>
      <groupId>io.swagger</groupId>
      <artifactId>swagger-annotations</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>io.prometheus</groupId>
      <artifactId>simpleclient</artifactId>
    </dependency>

    <dependency>
      <groupId>io.prometheus</groupId>
      <artifactId>simpleclient_jetty</artifactId>
    </dependency>

    <dependency>
      <groupId>io.prometheus</groupId>
      <artifactId>simpleclient_hotspot</artifactId>
    </dependency>

    <dependency>
      <groupId>io.prometheus</groupId>
      <artifactId>simpleclient_caffeine</artifactId>
    </dependency>

    <dependency>
      <groupId>io.swagger</groupId>
      <artifactId>swagger-core</artifactId>
      <scope>provided</scope>
    </dependency>

    <dependency>
      <groupId>org.hdrhistogram</groupId>
      <artifactId>HdrHistogram</artifactId>
    </dependency>

    <dependency>
      <groupId>com.google.code.gson</groupId>
      <artifactId>gson</artifactId>
    </dependency>

    <dependency>
      <groupId>com.github.zafarkhaja</groupId>
      <artifactId>java-semver</artifactId>
    </dependency>

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

    <dependency>
      <groupId>com.carrotsearch</groupId>
      <artifactId>hppc</artifactId>
    </dependency>

    <dependency>
      <groupId>org.roaringbitmap</groupId>
      <artifactId>RoaringBitmap</artifactId>
    </dependency>

    <dependency>
      <groupId>com.github.oshi</groupId>
      <artifactId>oshi-core-java11</artifactId>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-functions-api-examples</artifactId>
      <version>${project.version}</version>
      <type>pom</type>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-functions-api-examples-builtin</artifactId>
      <version>${project.version}</version>
      <type>pom</type>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-io-batch-data-generator</artifactId>
      <version>${project.version}</version>
      <type>pom</type>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-io-data-generator</artifactId>
      <version>${project.version}</version>
      <type>pom</type>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-metadata</artifactId>
      <version>${project.version}</version>
      <type>test-jar</type>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>jakarta.xml.bind</groupId>
      <artifactId>jakarta.xml.bind-api</artifactId>
      <exclusions>
        <exclusion>
          <groupId>javax.activation</groupId>
          <artifactId>javax.activation-api</artifactId>
        </exclusion>
      </exclusions>
    </dependency>

    <dependency>
      <groupId>com.sun.activation</groupId>
      <artifactId>jakarta.activation</artifactId>
    </dependency>

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

    <!-- transaction related dependencies (begin) -->

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-transaction-coordinator</artifactId>
      <version>${project.version}</version>
    </dependency>

    <!-- transaction related dependencies (end) -->

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-package-core</artifactId>
      <version>${project.version}</version>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>jetcd-core-shaded</artifactId>
      <version>${project.version}</version>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>io.grpc</groupId>
      <artifactId>grpc-netty-shaded</artifactId>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>io.etcd</groupId>
      <artifactId>jetcd-test</artifactId>
      <scope>test</scope>
    </dependency>

    <dependency>
      <groupId>${project.groupId}</groupId>
      <artifactId>pulsar-package-filesystem-storage</artifactId>
      <version>${project.version}</version>
    </dependency>
  </dependencies>

  <build>
    <plugins>
      <plugin>
        <groupId>org.gaul</groupId>
        <artifactId>modernizer-maven-plugin</artifactId>
        <configuration>
          <failOnViolations>true</failOnViolations>
          <javaVersion>17</javaVersion>
          <exclusionPatterns>
            <exclusionPattern>java/lang/StringBuffer."&lt;init&gt;":.*</exclusionPattern>
          </exclusionPatterns>
        </configuration>
        <executions>
          <execution>
            <id>modernizer</id>
            <phase>verify</phase>
            <goals>
              <goal>modernizer</goal>
            </goals>
          </execution>
        </executions>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-checkstyle-plugin</artifactId>
        <executions>
          <execution>
            <id>check-style</id>
            <phase>verify</phase>
            <configuration>
              <configLocation>../buildtools/src/main/resources/pulsar/checkstyle.xml</configLocation>
              <suppressionsLocation>../buildtools/src/main/resources/pulsar/suppressions.xml</suppressionsLocation>
              <encoding>UTF-8</encoding>
              <excludes>**/proto/*</excludes>
            </configuration>
            <goals>
              <goal>check</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-jar-plugin</artifactId>
        <executions>
          <execution>
            <goals>
              <goal>test-jar</goal>
            </goals>
          </execution>
        </executions>
      </plugin>

      <plugin>
        <artifactId>maven-dependency-plugin</artifactId>
        <executions>
          <execution>
            <id>copy-pulsar-io-connectors</id>
            <phase>generate-test-resources</phase>
            <goals>
              <goal>copy</goal>
            </goals>
            <configuration>
              <artifactItems>
                <artifactItem>
                  <groupId>${project.groupId}</groupId>
                  <artifactId>pulsar-io-data-generator</artifactId>
                  <version>${project.version}</version>
                  <type>jar</type>
                  <overWrite>true</overWrite>
                  <outputDirectory>${project.build.directory}</outputDirectory>
                  <destFileName>pulsar-io-data-generator.nar</destFileName>
                </artifactItem>
                <artifactItem>
                  <groupId>${project.groupId}</groupId>
                  <artifactId>pulsar-io-batch-data-generator</artifactId>
                  <version>${project.version}</version>
                  <type>jar</type>
                  <overWrite>true</overWrite>
                  <outputDirectory>${project.build.directory}</outputDirectory>
                  <destFileName>pulsar-io-batch-data-generator.nar</destFileName>
                </artifactItem>
                <artifactItem>
                  <groupId>${project.groupId}</groupId>
                  <artifactId>pulsar-functions-api-examples</artifactId>
                  <version>${project.version}</version>
                  <type>jar</type>
                  <overWrite>true</overWrite>
                  <outputDirectory>${project.build.directory}</outputDirectory>
                  <destFileName>pulsar-functions-api-examples.jar</destFileName>
                </artifactItem>
                <artifactItem>
                  <groupId>${project.groupId}</groupId>
                  <artifactId>pulsar-functions-api-examples-builtin</artifactId>
                  <version>${project.version}</version>
                  <type>jar</type>
                  <overWrite>true</overWrite>
                  <outputDirectory>${project.build.directory}</outputDirectory>
                  <destFileName>pulsar-functions-api-examples.nar</destFileName>
                </artifactItem>
              </artifactItems>
            </configuration>
          </execution>
        </executions>
      </plugin>

      <plugin>
        <groupId>org.apache.maven.plugins</groupId>
        <artifactId>maven-surefire-plugin</artifactId>
        <configuration>
          <systemPropertyVariables>
            <pulsar-io-data-generator.nar.path>${project.build.directory}/pulsar-io-data-generator.nar</pulsar-io-data-generator.nar.path>
            <pulsar-functions-api-examples.jar.path>${project.build.directory}/pulsar-functions-api-examples.jar</pulsar-functions-api-examples.jar.path>
            <pulsar-functions-api-examples.nar.path>${project.build.directory}/pulsar-functions-api-examples.nar</pulsar-functions-api-examples.nar.path>
            <pulsar-io-batch-data-generator.nar.path>${project.build.directory}/pulsar-io-batch-data-generator.nar</pulsar-io-batch-data-generator.nar.path>
            <!-- workaround issue #13750 which gets triggered if org.apache.bookkeeper.meta.MetadataDrivers class gets loaded before org.apache.pulsar.metadata.bookkeeper.BKCluster constructor is called -->
            <bookkeeper.metadata.bookie.drivers>org.apache.pulsar.metadata.bookkeeper.PulsarMetadataBookieDriver</bookkeeper.metadata.bookie.drivers>
            <bookkeeper.metadata.client.drivers>org.apache.pulsar.metadata.bookkeeper.PulsarMetadataClientDriver</bookkeeper.metadata.client.drivers>
          </systemPropertyVariables>
        </configuration>
      </plugin>

      <plugin>
        <groupId>org.xolstice.maven.plugins</groupId>
        <artifactId>protobuf-maven-plugin</artifactId>
        <version>${protobuf-maven-plugin.version}</version>
        <configuration>
          <!--suppress UnresolvedMavenProperty -->
          <protocArtifact>com.google.protobuf:protoc:${protoc3.version}:exe:${os.detected.classifier}</protocArtifact>
          <checkStaleness>true</checkStaleness>
          <excludes>
            <exclude>**/ResourceUsage.proto</exclude>
            <exclude>**/TransactionPendingAck.proto</exclude>
            <exclude>**/DelayedMessageIndexBucketSegment.proto</exclude>
          </excludes>
        </configuration>
        <executions>
          <execution>
            <phase>generate-sources</phase>
            <goals>
              <goal>compile</goal>
              <goal>test-compile</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>com.github.splunk.lightproto</groupId>
        <artifactId>lightproto-maven-plugin</artifactId>
        <version>${lightproto-maven-plugin.version}</version>
        <configuration>
          <sources>
            <source>${project.basedir}/src/main/proto/TransactionPendingAck.proto</source>
            <source>${project.basedir}/src/main/proto/ResourceUsage.proto</source>
            <source>${project.basedir}/src/main/proto/DelayedMessageIndexBucketSegment.proto</source>
          </sources>
          <targetSourcesSubDir>generated-sources/lightproto/java</targetSourcesSubDir>
          <targetTestSourcesSubDir>generated-sources/lightproto/java</targetTestSourcesSubDir>
        </configuration>
        <executions>
          <execution>
            <goals>
              <goal>generate</goal>
            </goals>
          </execution>
        </executions>
      </plugin>
      <plugin>
        <groupId>org.codehaus.mojo</groupId>
        <artifactId>build-helper-maven-plugin</artifactId>
        <version>${build-helper-maven-plugin.version}</version>
        <executions>
          <execution>
            <id>add-source</id>
            <phase>generate-sources</phase>
            <goals>
              <goal>add-source</goal>
            </goals>
            <configuration>
              <sources>
                <source>target/generated-sources/lightproto/java</source>
              </sources>
            </configuration>
          </execution>
        </executions>
      </plugin>

      <plugin>
        <artifactId>maven-resources-plugin</artifactId>
        <executions>
          <execution>
            <id>copy-resources</id>
            <phase>test-compile</phase>
            <goals>
              <goal>copy-resources</goal>
            </goals>
            <configuration>
              <outputDirectory>${project.build.testOutputDirectory}/certificate-authority</outputDirectory>
              <overwrite>true</overwrite>
              <resources>
                <resource>
                  <directory>${project.parent.basedir}/tests/certificate-authority</directory>
                  <filtering>false</filtering>
                </resource>
              </resources>
            </configuration>
          </execution>
        </executions>
      </plugin>
    </plugins>
    <resources>
      <resource>
        <directory>src/main/resources</directory>
        <filtering>true</filtering>
      </resource>
    </resources>
  </build>

  <profiles>
    <profile>
      <!-- enables builds with -Dmaven.test.skip=true -->
      <id>test-jar-dependencies</id>
      <activation>
        <property>
          <name>maven.test.skip</name>
          <value>!true</value>
        </property>
      </activation>
      <dependencies>
        <dependency>
          <groupId>${project.groupId}</groupId>
          <artifactId>managed-ledger</artifactId>
          <version>${project.version}</version>
          <type>test-jar</type>
          <scope>test</scope>
        </dependency>

        <dependency>
          <groupId>${project.groupId}</groupId>
          <artifactId>pulsar-package-core</artifactId>
          <version>${project.version}</version>
          <type>test-jar</type>
          <scope>test</scope>
        </dependency>

        <dependency>
          <groupId>${project.groupId}</groupId>
          <artifactId>pulsar-metadata</artifactId>
          <version>${project.version}</version>
          <type>test-jar</type>
          <scope>test</scope>
        </dependency>
      </dependencies>
    </profile>
    <profile>
      <id>swagger</id>
      <build>
        <plugins>
          <plugin>
            <groupId>com.github.kongchen</groupId>
            <artifactId>swagger-maven-plugin</artifactId>
            <version>3.1.8</version>
            <configuration>
              <apiSources>
                <apiSource>
                  <springmvc>false</springmvc>
                  <operationIdFormat>{{className}}_{{methodName}}</operationIdFormat>
                  <outputFormats>json</outputFormats>
                  <locations>
                    <location>org.apache.pulsar.broker.admin.v2.Bookies</location>
                    <location>org.apache.pulsar.broker.admin.v2.BrokerStats</location>
                    <location>org.apache.pulsar.broker.admin.v2.Brokers</location>
                    <location>org.apache.pulsar.broker.admin.v2.Clusters</location>
                    <location>org.apache.pulsar.broker.admin.v2.Functions</location>
                    <location>org.apache.pulsar.broker.admin.v2.Namespaces</location>
                    <location>org.apache.pulsar.broker.admin.v2.NonPersistentTopics</location>
                    <location>org.apache.pulsar.broker.admin.v2.PersistentTopics</location>
                    <!-- See https://github.com/apache/pulsar/issues/18947 -->
                    <!-- <location>org.apache.pulsar.broker.admin.v2.ExtPersistentTopics</location> -->
                    <!-- <location>org.apache.pulsar.broker.admin.v2.ExtNonPersistentTopics</location> -->
                    <location>org.apache.pulsar.broker.admin.v2.ResourceGroups</location>
                    <location>org.apache.pulsar.broker.admin.v2.ResourceQuotas</location>
                    <location>org.apache.pulsar.broker.admin.v2.SchemasResource</location>
                    <location>org.apache.pulsar.broker.admin.v2.Tenants</location>
                    <location>org.apache.pulsar.broker.admin.v2.Worker</location>
                    <location>org.apache.pulsar.broker.admin.v2.WorkerStats</location>
                  </locations>
                  <schemes>http,https</schemes>
                  <basePath>/admin/v2</basePath>
                  <info>
                    <title>Pulsar Admin REST API</title>
                    <version>v2</version>
                    <description>This provides the REST API for admin operations</description>
                    <license>
                      <url>http://www.apache.org/licenses/LICENSE-2.0.html</url>
                      <name>Apache 2.0</name>
                    </license>
                  </info>
                  <swaggerDirectory>${basedir}/target/docs</swaggerDirectory>
                  <swaggerFileName>swagger</swaggerFileName>
                </apiSource>
                <apiSource>
                  <springmvc>false</springmvc>
                  <operationIdFormat>{{className}}_{{methodName}}</operationIdFormat>
                  <outputFormats>json</outputFormats>
                  <locations>org.apache.pulsar.broker.lookup.v2</locations>
                  <schemes>http,https</schemes>
                  <basePath>/lookup</basePath>
                  <info>
                    <title>Pulsar Lookup REST API</title>
                    <version>v2</version>
                    <description>This provides the REST API for lookup operations</description>
                    <license>
                      <url>http://www.apache.org/licenses/LICENSE-2.0.html</url>
                      <name>Apache 2.0</name>
                    </license>
                  </info>
                  <swaggerDirectory>${basedir}/target/docs</swaggerDirectory>
                  <swaggerFileName>swaggerlookup</swaggerFileName>
                </apiSource>
                <apiSource>
                  <springmvc>false</springmvc>
                  <operationIdFormat>{{className}}_{{methodName}}</operationIdFormat>
                  <outputFormats>json</outputFormats>
                  <locations>org.apache.pulsar.broker.admin.v3.Functions</locations>
                  <schemes>http,https</schemes>
                  <basePath>/admin/v3</basePath>
                  <info>
                    <title>Pulsar Functions REST API</title>
                    <version>v3</version>
                    <description>This provides the REST API for Pulsar Functions operations</description>
                    <license>
                      <url>http://www.apache.org/licenses/LICENSE-2.0.html</url>
                      <name>Apache 2.0</name>
                    </license>
                  </info>
                  <swaggerDirectory>${basedir}/target/docs</swaggerDirectory>
                  <swaggerFileName>swaggerfunctions</swaggerFileName>
                </apiSource>
                <apiSource>
                  <springmvc>false</springmvc>
                  <operationIdFormat>{{className}}_{{methodName}}</operationIdFormat>
                  <outputFormats>json</outputFormats>
                  <locations>org.apache.pulsar.broker.admin.v3.Transactions</locations>
                  <schemes>http,https</schemes>
                  <basePath>/admin/v3</basePath>
                  <info>
                    <title>Pulsar Transactions REST API</title>
                    <version>v3</version>
                    <description>This provides the REST API for Pulsar Transactions operations</description>
                    <license>
                      <url>http://www.apache.org/licenses/LICENSE-2.0.html</url>
                      <name>Apache 2.0</name>
                    </license>
                  </info>
                  <swaggerDirectory>${basedir}/target/docs</swaggerDirectory>
                  <swaggerFileName>swaggertransactions</swaggerFileName>
                </apiSource>
                <apiSource>
                  <springmvc>false</springmvc>
                  <operationIdFormat>{{className}}_{{methodName}}</operationIdFormat>
                  <outputFormats>json</outputFormats>
                  <locations>org.apache.pulsar.broker.admin.v3.Sources</locations>
                  <schemes>http,https</schemes>
                  <basePath>/admin/v3</basePath>
                  <info>
                    <title>Pulsar Source REST API</title>
                    <version>v3</version>
                    <description>This provides the REST API for Pulsar Source operations</description>
                    <license>
                      <url>http://www.apache.org/licenses/LICENSE-2.0.html</url>
                      <name>Apache 2.0</name>
                    </license>
                  </info>
                  <swaggerDirectory>${basedir}/target/docs</swaggerDirectory>
                  <swaggerFileName>swaggersource</swaggerFileName>
                </apiSource>
                <apiSource>
                  <springmvc>false</springmvc>
                  <operationIdFormat>{{className}}_{{methodName}}</operationIdFormat>
                  <outputFormats>json</outputFormats>
                  <locations>org.apache.pulsar.broker.admin.v3.Sinks</locations>
                  <schemes>http,https</schemes>
                  <basePath>/admin/v3</basePath>
                  <info>
                    <title>Pulsar Sink REST API</title>
                    <version>v3</version>
                    <description>This provides the REST API for Pulsar Sink operations</description>
                    <license>
                      <url>http://www.apache.org/licenses/LICENSE-2.0.html</url>
                      <name>Apache 2.0</name>
                    </license>
                  </info>
                  <swaggerDirectory>${basedir}/target/docs</swaggerDirectory>
                  <swaggerFileName>swaggersink</swaggerFileName>
                </apiSource>
                <apiSource>
                  <springmvc>false</springmvc>
                  <operationIdFormat>{{className}}_{{methodName}}</operationIdFormat>
                  <outputFormats>json</outputFormats>
                  <locations>org.apache.pulsar.broker.admin.v3.Packages</locations>
                  <schemes>http,https</schemes>
                  <basePath>/admin/v3</basePath>
                  <info>
                    <title>Pulsar Packages REST API</title>
                    <version>v3</version>
                    <description>This provides the REST API for Pulsar Packages operations</description>
                    <license>
                      <url>http://www.apache.org/licenses/LICENSE-2.0.html</url>
                      <name>Apache 2.0</name>
                    </license>
                  </info>
                  <swaggerDirectory>${basedir}/target/docs</swaggerDirectory>
                  <swaggerFileName>swaggerpackages</swaggerFileName>
                </apiSource>
              </apiSources>
            </configuration>
            <executions>
              <execution>
                <phase>compile</phase>
                <goals>
                  <goal>generate</goal>
                </goals>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
    </profile>
    <profile>
      <id>only-eclipse</id>
      <activation>
        <property>
          <name>m2e.version</name>
        </property>
      </activation>
      <build>
        <pluginManagement>
          <plugins>
            <plugin>
              <!--This plugin's configuration is used to store Eclipse m2e settings only.
                  It has no influence on the Maven build itself.-->
              <groupId>org.eclipse.m2e</groupId>
              <artifactId>lifecycle-mapping</artifactId>
              <version>1.0.0</version>
              <configuration>
                <lifecycleMappingMetadata>
                  <pluginExecutions>
                    <pluginExecution>
                      <pluginExecutionFilter>
                        <groupId>org.apache.maven.plugins</groupId>
                        <artifactId>maven-remote-resources-plugin</artifactId>
                        <versionRange>[1.5,)</versionRange>
                        <goals>
                          <goal>process</goal>
                        </goals>
                      </pluginExecutionFilter>
                      <action>
                        <ignore/>
                      </action>
                    </pluginExecution>
                  </pluginExecutions>
                </lifecycleMappingMetadata>
              </configuration>
            </plugin>
          </plugins>
        </pluginManagement>
      </build>
    </profile>
    <profile>
      <id>skipTestsForUnitGroupOther</id>
      <build>
        <plugins>
          <plugin>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-surefire-plugin</artifactId>
            <configuration>
              <skipTests>true</skipTests>
            </configuration>
          </plugin>
        </plugins>
      </build>
    </profile>
  </profiles>
</project>
