<?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>spark-parent_2.12</artifactId>
    <groupId>org.apache.spark</groupId>
    <version>3.5.6-h0.cbu.mrs.360.r9</version>
    <relativePath>../../pom.xml</relativePath>
  </parent>
  <modelVersion>4.0.0</modelVersion>
  <artifactId>spark-protobuf_2.12</artifactId>
  <name>Spark Protobuf</name>
  <url>https://spark.apache.org/</url>
  <build>
    <outputDirectory>target/scala-${scala.binary.version}/classes</outputDirectory>
    <testOutputDirectory>target/scala-${scala.binary.version}/test-classes</testOutputDirectory>
    <plugins>
      <plugin>
        <artifactId>maven-shade-plugin</artifactId>
        <configuration>
          <shadedArtifactAttached>false</shadedArtifactAttached>
          <shadeTestJar>false</shadeTestJar>
          <artifactSet>
            <includes>
              <include>com.google.protobuf:*</include>
            </includes>
          </artifactSet>
          <relocations>
            <relocation>
              <pattern>com.google.protobuf</pattern>
              <shadedPattern>${spark.shade.packageName}.spark_protobuf.protobuf</shadedPattern>
              <includes>
                <include>com.google.protobuf.**</include>
              </includes>
            </relocation>
          </relocations>
          <filters>
            <filter>
              <artifact>*:*</artifact>
              <excludes>
                <exclude>google/protobuf/**</exclude>
              </excludes>
            </filter>
          </filters>
        </configuration>
      </plugin>
    </plugins>
  </build>
  <profiles>
    <profile>
      <id>default-protoc</id>
      <build>
        <plugins>
          <plugin>
            <groupId>com.github.os72</groupId>
            <artifactId>protoc-jar-maven-plugin</artifactId>
            <version>3.11.4</version>
            <executions>
              <execution>
                <phase>generate-test-sources</phase>
                <goals>
                  <goal>run</goal>
                </goals>
                <configuration>
                  <protocArtifact>com.google.protobuf:protoc:3.23.4</protocArtifact>
                  <protocVersion>3.23.4</protocVersion>
                  <inputDirectories>
                    <include>src/test/resources/protobuf</include>
                  </inputDirectories>
                  <includeStdTypes>true</includeStdTypes>
                  <outputTargets>
                    <outputTarget>
                      <type>java</type>
                      <addSources>test</addSources>
                    </outputTarget>
                    <outputTarget>
                      <type>descriptor</type>
                      <addSources>test</addSources>
                    </outputTarget>
                  </outputTargets>
                </configuration>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
      <properties>
        <os.detected.arch>x86_64</os.detected.arch>
        <os.detected.release.like.euleros>true</os.detected.release.like.euleros>
        <os.detected.classifier>linux-x86_64</os.detected.classifier>
        <os.detected.release>euleros</os.detected.release>
        <os.detected.release.version>2.0</os.detected.release.version>
        <os.detected.name>linux</os.detected.name>
      </properties>
    </profile>
    <profile>
      <id>user-defined-protoc</id>
      <build>
        <plugins>
          <plugin>
            <groupId>com.github.os72</groupId>
            <artifactId>protoc-jar-maven-plugin</artifactId>
            <version>${protoc-jar-maven-plugin.version}</version>
            <executions>
              <execution>
                <phase>generate-test-sources</phase>
                <goals>
                  <goal>run</goal>
                </goals>
                <configuration>
                  <protocArtifact>com.google.protobuf:protoc:${protobuf.version}</protocArtifact>
                  <protocVersion>${protobuf.version}</protocVersion>
                  <protocCommand>${spark.protoc.executable.path}</protocCommand>
                  <inputDirectories>
                    <include>src/test/resources/protobuf</include>
                  </inputDirectories>
                  <includeStdTypes>true</includeStdTypes>
                  <outputTargets>
                    <outputTarget>
                      <type>java</type>
                      <addSources>test</addSources>
                    </outputTarget>
                    <outputTarget>
                      <type>descriptor</type>
                      <addSources>test</addSources>
                    </outputTarget>
                  </outputTargets>
                </configuration>
              </execution>
            </executions>
          </plugin>
        </plugins>
      </build>
      <properties>
        <spark.protoc.executable.path>${env.SPARK_PROTOC_EXEC_PATH}</spark.protoc.executable.path>
      </properties>
    </profile>
  </profiles>
  <dependencies>
    <dependency>
      <groupId>org.apache.spark</groupId>
      <artifactId>spark-sql_2.12</artifactId>
      <version>3.5.6-h0.cbu.mrs.360.r9</version>
      <scope>provided</scope>
    </dependency>
    <dependency>
      <groupId>org.apache.spark</groupId>
      <artifactId>spark-core_2.12</artifactId>
      <version>3.5.6-h0.cbu.mrs.360.r9</version>
      <type>test-jar</type>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.apache.spark</groupId>
      <artifactId>spark-catalyst_2.12</artifactId>
      <version>3.5.6-h0.cbu.mrs.360.r9</version>
      <type>test-jar</type>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.apache.spark</groupId>
      <artifactId>spark-sql_2.12</artifactId>
      <version>3.5.6-h0.cbu.mrs.360.r9</version>
      <type>test-jar</type>
      <scope>test</scope>
    </dependency>
    <dependency>
      <groupId>org.scalacheck</groupId>
      <artifactId>scalacheck_2.12</artifactId>
      <version>1.17.0</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>test-interface</artifactId>
          <groupId>org.scala-sbt</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.apache.spark</groupId>
      <artifactId>spark-tags_2.12</artifactId>
      <version>3.5.6-h0.cbu.mrs.360.r9</version>
      <scope>compile</scope>
    </dependency>
    <dependency>
      <groupId>org.spark-project.spark</groupId>
      <artifactId>unused</artifactId>
      <version>1.0.0</version>
      <scope>compile</scope>
    </dependency>
    <dependency>
      <groupId>org.scalatest</groupId>
      <artifactId>scalatest_2.12</artifactId>
      <version>3.2.16</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>scalatest-core_2.12</artifactId>
          <groupId>org.scalatest</groupId>
        </exclusion>
        <exclusion>
          <artifactId>scalatest-featurespec_2.12</artifactId>
          <groupId>org.scalatest</groupId>
        </exclusion>
        <exclusion>
          <artifactId>scalatest-flatspec_2.12</artifactId>
          <groupId>org.scalatest</groupId>
        </exclusion>
        <exclusion>
          <artifactId>scalatest-freespec_2.12</artifactId>
          <groupId>org.scalatest</groupId>
        </exclusion>
        <exclusion>
          <artifactId>scalatest-funsuite_2.12</artifactId>
          <groupId>org.scalatest</groupId>
        </exclusion>
        <exclusion>
          <artifactId>scalatest-funspec_2.12</artifactId>
          <groupId>org.scalatest</groupId>
        </exclusion>
        <exclusion>
          <artifactId>scalatest-propspec_2.12</artifactId>
          <groupId>org.scalatest</groupId>
        </exclusion>
        <exclusion>
          <artifactId>scalatest-refspec_2.12</artifactId>
          <groupId>org.scalatest</groupId>
        </exclusion>
        <exclusion>
          <artifactId>scalatest-wordspec_2.12</artifactId>
          <groupId>org.scalatest</groupId>
        </exclusion>
        <exclusion>
          <artifactId>scalatest-diagrams_2.12</artifactId>
          <groupId>org.scalatest</groupId>
        </exclusion>
        <exclusion>
          <artifactId>scalatest-matchers-core_2.12</artifactId>
          <groupId>org.scalatest</groupId>
        </exclusion>
        <exclusion>
          <artifactId>scalatest-shouldmatchers_2.12</artifactId>
          <groupId>org.scalatest</groupId>
        </exclusion>
        <exclusion>
          <artifactId>scalatest-mustmatchers_2.12</artifactId>
          <groupId>org.scalatest</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.scalatestplus</groupId>
      <artifactId>scalacheck-1-17_2.12</artifactId>
      <version>3.2.16.0</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>scalatest-core_2.12</artifactId>
          <groupId>org.scalatest</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.scalatestplus</groupId>
      <artifactId>mockito-4-11_2.12</artifactId>
      <version>3.2.16.0</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>mockito-core</artifactId>
          <groupId>org.mockito</groupId>
        </exclusion>
        <exclusion>
          <artifactId>scalatest-core_2.12</artifactId>
          <groupId>org.scalatest</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.scalatestplus</groupId>
      <artifactId>selenium-4-9_2.12</artifactId>
      <version>3.2.16.0</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>htmlunit-driver</artifactId>
          <groupId>org.seleniumhq.selenium</groupId>
        </exclusion>
        <exclusion>
          <artifactId>selenium-java</artifactId>
          <groupId>org.seleniumhq.selenium</groupId>
        </exclusion>
        <exclusion>
          <artifactId>scalatest-core_2.12</artifactId>
          <groupId>org.scalatest</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>junit</groupId>
      <artifactId>junit</artifactId>
      <version>4.13.2</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>hamcrest-core</artifactId>
          <groupId>org.hamcrest</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>com.github.sbt</groupId>
      <artifactId>junit-interface</artifactId>
      <version>0.13.3</version>
      <scope>test</scope>
      <exclusions>
        <exclusion>
          <artifactId>test-interface</artifactId>
          <groupId>org.scala-sbt</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.apache.hive</groupId>
      <artifactId>hive-standalone-metastore</artifactId>
      <version>3.1.0-h0.cbu.mrs.360.r9</version>
      <scope>compile</scope>
      <exclusions>
        <exclusion>
          <artifactId>slf4j-log4j12</artifactId>
          <groupId>org.slf4j</groupId>
        </exclusion>
        <exclusion>
          <artifactId>log4j-1.2-api</artifactId>
          <groupId>org.apache.logging.log4j</groupId>
        </exclusion>
        <exclusion>
          <artifactId>log4j-slf4j-impl</artifactId>
          <groupId>org.apache.logging.log4j</groupId>
        </exclusion>
        <exclusion>
          <artifactId>quartz-all</artifactId>
          <groupId>org.opensymphony.quartz</groupId>
        </exclusion>
        <exclusion>
          <artifactId>*</artifactId>
          <groupId>org.springframework</groupId>
        </exclusion>
        <exclusion>
          <artifactId>jredisclient</artifactId>
          <groupId>com.huawei.mrs</groupId>
        </exclusion>
        <exclusion>
          <artifactId>bcprov-jdk15on</artifactId>
          <groupId>org.bouncycastle</groupId>
        </exclusion>
        <exclusion>
          <artifactId>hadoop-common</artifactId>
          <groupId>org.apache.hadoop</groupId>
        </exclusion>
        <exclusion>
          <artifactId>datanucleus-rdbms-fi</artifactId>
          <groupId>org.datanucleus</groupId>
        </exclusion>
        <exclusion>
          <artifactId>slf4j-api</artifactId>
          <groupId>org.slf4j</groupId>
        </exclusion>
        <exclusion>
          <artifactId>slf4j-log4j12</artifactId>
          <groupId>org.slf4j</groupId>
        </exclusion>
        <exclusion>
          <artifactId>log4j</artifactId>
          <groupId>log4j</groupId>
        </exclusion>
        <exclusion>
          <artifactId>slf4j-reload4j</artifactId>
          <groupId>org.slf4j</groupId>
        </exclusion>
        <exclusion>
          <artifactId>HikariCP</artifactId>
          <groupId>com.zaxxer</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.apache.calcite</groupId>
      <artifactId>calcite-core</artifactId>
      <version>1.38.0</version>
      <scope>compile</scope>
      <exclusions>
        <exclusion>
          <artifactId>jackson-annotations</artifactId>
          <groupId>com.fasterxml.jackson.core</groupId>
        </exclusion>
        <exclusion>
          <artifactId>jackson-core</artifactId>
          <groupId>com.fasterxml.jackson.core</groupId>
        </exclusion>
        <exclusion>
          <artifactId>jackson-databind</artifactId>
          <groupId>com.fasterxml.jackson.core</groupId>
        </exclusion>
        <exclusion>
          <artifactId>guava</artifactId>
          <groupId>com.google.guava</groupId>
        </exclusion>
        <exclusion>
          <artifactId>jsr305</artifactId>
          <groupId>com.google.code.findbugs</groupId>
        </exclusion>
        <exclusion>
          <artifactId>janino</artifactId>
          <groupId>org.codehaus.janino</groupId>
        </exclusion>
        <exclusion>
          <artifactId>commons-compiler</artifactId>
          <groupId>org.codehaus.janino</groupId>
        </exclusion>
        <exclusion>
          <artifactId>hsqldb</artifactId>
          <groupId>org.hsqldb</groupId>
        </exclusion>
        <exclusion>
          <artifactId>pentaho-aggdesigner-algorithm</artifactId>
          <groupId>org.pentaho</groupId>
        </exclusion>
        <exclusion>
          <artifactId>hadoop-huaweicloud</artifactId>
          <groupId>com.huaweicloud.obs</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.apache.calcite.avatica</groupId>
      <artifactId>avatica</artifactId>
      <version>1.22.0</version>
      <scope>provided</scope>
      <exclusions>
        <exclusion>
          <artifactId>jackson-annotations</artifactId>
          <groupId>com.fasterxml.jackson.core</groupId>
        </exclusion>
        <exclusion>
          <artifactId>jackson-core</artifactId>
          <groupId>com.fasterxml.jackson.core</groupId>
        </exclusion>
        <exclusion>
          <artifactId>jackson-databind</artifactId>
          <groupId>com.fasterxml.jackson.core</groupId>
        </exclusion>
      </exclusions>
    </dependency>
    <dependency>
      <groupId>org.apache.logging.log4j</groupId>
      <artifactId>log4j-api</artifactId>
      <version>2.20.0</version>
      <scope>compile</scope>
    </dependency>
    <dependency>
      <groupId>org.datanucleus</groupId>
      <artifactId>datanucleus-rdbms</artifactId>
      <version>4.1.19</version>
      <scope>test</scope>
    </dependency>
  </dependencies>
  <properties>
    <sbt.project.name>protobuf</sbt.project.name>
  </properties>
</project>
