<?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>zeppelin</artifactId>
    <groupId>org.apache.zeppelin</groupId>
    <version>0.12.1</version>
  </parent>
  <modelVersion>4.0.0</modelVersion>
  <artifactId>zeppelin-interpreter-shaded</artifactId>
  <name>Zeppelin: Interpreter Shaded</name>
  <description>Zeppelin Interpreter Shaded</description>
  <build>
    <plugins>
      <plugin>
        <artifactId>maven-shade-plugin</artifactId>
        <executions>
          <execution>
            <phase>package</phase>
            <goals>
              <goal>shade</goal>
            </goals>
          </execution>
        </executions>
        <configuration>
          <artifactSet>
            <excludes>
              <exclude>org.slf4j:*</exclude>
              <exclude>log4j:log4j</exclude>
              <exclude>ch.qos.reload4j:reload4j</exclude>
            </excludes>
          </artifactSet>
          <filters>
            <filter>
              <artifact>*:*</artifact>
              <excludes>
                <exclude>META-INF/*.SF</exclude>
                <exclude>META-INF/*.DSA</exclude>
                <exclude>META-INF/*.RSA</exclude>
              </excludes>
            </filter>
          </filters>
          <transformers>
            <transformer />
            <transformer>
              <resource>reference.conf</resource>
            </transformer>
            <transformer />
            <transformer>
              <resource>NOTICE.txt</resource>
            </transformer>
            <transformer>
              <resource>META-INF/LICENSE.txt</resource>
              <file>${basedir}/../../LICENSE.txt</file>
            </transformer>
            <transformer>
              <resource>META-INF/NOTICE.txt</resource>
              <file>${basedir}/../../NOTICE.txt</file>
            </transformer>
          </transformers>
          <relocations>
            <relocation>
              <pattern>org</pattern>
              <shadedPattern>${shaded.dependency.prefix}.org</shadedPattern>
              <excludes>
                <exclude>org/apache/zeppelin/*</exclude>
                <exclude>org/apache/zeppelin/**/*</exclude>
                <exclude>org/apache/hadoop/*</exclude>
                <exclude>org/apache/hadoop/**</exclude>
                <exclude>org/slf4j/*</exclude>
                <exclude>org/slf4j/**/*</exclude>
                <exclude>org/apache/commons/logging/*</exclude>
                <exclude>org/apache/commons/logging/**/*</exclude>
                <exclude>org/apache/commons/exec/*</exclude>
                <exclude>org/apache/commons/exec/**/*</exclude>
                <exclude>org/apache/log4j/*</exclude>
                <exclude>org/apache/log4j/**/*</exclude>
                <exclude>org/sonatype/*</exclude>
                <exclude>org/sonatype/**/*</exclude>
                <exclude>**/pom.xml</exclude>
                <exclude>org/ietf/jgss/*</exclude>
                <exclude>org/omg/**/*</exclude>
                <exclude>org/w3c/dom/*</exclude>
                <exclude>org/w3c/dom/**/*</exclude>
                <exclude>org/xml/sax/*</exclude>
                <exclude>org/xml/sax/**/*</exclude>
                <exclude>org/eclipse/sisu/**</exclude>
              </excludes>
            </relocation>
            <relocation>
              <pattern>com.google</pattern>
              <shadedPattern>${shaded.dependency.prefix}.com.google</shadedPattern>
            </relocation>
            <relocation>
              <pattern>io</pattern>
              <shadedPattern>${shaded.dependency.prefix}.io</shadedPattern>
            </relocation>
            <relocation>
              <pattern>com.esotericsoftware</pattern>
              <shadedPattern>${shaded.dependency.prefix}.com.esotericsoftware</shadedPattern>
            </relocation>
          </relocations>
        </configuration>
      </plugin>
      <plugin>
        <artifactId>maven-antrun-plugin</artifactId>
        <executions>
          <execution>
            <id>copy-to-interpreter</id>
            <phase>package</phase>
            <goals>
              <goal>run</goal>
            </goals>
            <configuration>
              <target>
                <echo>ANT TASK - clean files....</echo>
                <delete>
                  <fileset />
                </delete>
                <echo>ANT TASK - copying files....</echo>
                <copy>
                  <fileset />
                </copy>
              </target>
            </configuration>
          </execution>
        </executions>
      </plugin>
    </plugins>
  </build>
  <properties>
    <shaded.dependency.prefix>shaded.org.apache.zeppelin</shaded.dependency.prefix>
  </properties>
</project>
