ZEPPELIN-2982. Copy interpreter-setting.json to interpreter dir ### What is this PR for? 2 main changes. * Introduce `interpreter-parent` module, so that all the interpreter can reuse the plugin defined in `interpreter-parent` * Add new plugin for `copying interpreter-setting.json` to interpreter dir
### What type of PR is it? [ Improvement | Refactoring] ### Todos * [ ] - Task ### What is the Jira issue? * https://issues.apache.org/jira/browse/ZEPPELIN-2982 ### How should this be tested? * First time? Setup Travis CI as described on https://zeppelin.apache.org/contribution/contributions.html#continuous-integration * Strongly recommended: add automated unit tests for any new or changed behavior * Outline any manual steps to test the PR here. ### Screenshots (if appropriate) ### Questions: * Does the licenses files need update? No * Is there breaking changes for older versions? No * Does this needs documentation? No Author: Jeff Zhang <zjf...@apache.org> Closes #2613 from zjffdu/ZEPPELIN-2982 and squashes the following commits: ccccd32 [Jeff Zhang] update doc 8f643a7 [Jeff Zhang] ZEPPELIN-2982. Copy interpreter-setting.json to interpreter dir Project: http://git-wip-us.apache.org/repos/asf/zeppelin/repo Commit: http://git-wip-us.apache.org/repos/asf/zeppelin/commit/4a3057fa Tree: http://git-wip-us.apache.org/repos/asf/zeppelin/tree/4a3057fa Diff: http://git-wip-us.apache.org/repos/asf/zeppelin/diff/4a3057fa Branch: refs/heads/master Commit: 4a3057fa87fbe092f4a6b8dcc34e8f6866b7c700 Parents: 862871f Author: Jeff Zhang <zjf...@apache.org> Authored: Thu Oct 12 09:29:25 2017 +0800 Committer: Jeff Zhang <zjf...@apache.org> Committed: Fri Oct 13 13:51:22 2017 +0800 ---------------------------------------------------------------------- alluxio/pom.xml | 53 +------ angular/pom.xml | 56 ++------ beam/pom.xml | 64 +-------- bigquery/pom.xml | 85 ++++-------- cassandra/pom.xml | 54 +------- .../development/writing_zeppelin_interpreter.md | 44 +++++- elasticsearch/pom.xml | 53 +------ file/pom.xml | 59 +------- flink/pom.xml | 75 ++-------- geode/pom.xml | 52 +------ groovy/pom.xml | 81 ++--------- .../org/apache/zeppelin/groovy/GObject.java | 2 +- .../zeppelin/groovy/GroovyInterpreter.java | 2 +- hbase/pom.xml | 53 +------ helium-dev/pom.xml | 51 ++----- ignite/pom.xml | 54 +------- interpreter-parent/pom.xml | 138 +++++++++++++++++++ jdbc/pom.xml | 52 +------ kylin/pom.xml | 56 ++------ lens/pom.xml | 67 +-------- livy/pom.xml | 55 +------- markdown/pom.xml | 53 +------ pig/pom.xml | 55 +------- python/pom.xml | 61 ++------ scalding/pom.xml | 54 +------- scio/pom.xml | 45 ++---- shell/pom.xml | 57 ++------ zeppelin-interpreter/pom.xml | 75 ++++++++++ .../interpreter/InterpreterSettingManager.java | 11 +- 29 files changed, 456 insertions(+), 1161 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/alluxio/pom.xml ---------------------------------------------------------------------- diff --git a/alluxio/pom.xml b/alluxio/pom.xml index ed6b981..f36494e 100644 --- a/alluxio/pom.xml +++ b/alluxio/pom.xml @@ -20,10 +20,10 @@ <modelVersion>4.0.0</modelVersion> <parent> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> - <relativePath>..</relativePath> + <relativePath>../interpreter-parent</relativePath> </parent> <groupId>org.apache.zeppelin</groupId> @@ -34,6 +34,7 @@ <properties> <alluxio.version>1.0.0</alluxio.version> + <interpreter.name>alluxio</interpreter.name> </properties> <dependencies> @@ -129,54 +130,12 @@ <plugins> <plugin> <artifactId>maven-enforcer-plugin</artifactId> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> </plugin> - <plugin> <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/alluxio</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/alluxio</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> + </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> </plugin> </plugins> </build> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/angular/pom.xml ---------------------------------------------------------------------- diff --git a/angular/pom.xml b/angular/pom.xml index be43e49..9ff2acb 100644 --- a/angular/pom.xml +++ b/angular/pom.xml @@ -20,10 +20,10 @@ <modelVersion>4.0.0</modelVersion> <parent> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> - <relativePath>..</relativePath> + <relativePath>../interpreter-parent</relativePath> </parent> <groupId>org.apache.zeppelin</groupId> @@ -32,6 +32,10 @@ <version>0.8.0-SNAPSHOT</version> <name>Zeppelin: Angular interpreter</name> + <properties> + <interpreter.name>angular</interpreter.name> + </properties> + <dependencies> <dependency> <groupId>${project.groupId}</groupId> @@ -61,54 +65,12 @@ <plugins> <plugin> <artifactId>maven-enforcer-plugin</artifactId> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> </plugin> - <plugin> <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/angular</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/angular</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> + </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> </plugin> </plugins> </build> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/beam/pom.xml ---------------------------------------------------------------------- diff --git a/beam/pom.xml b/beam/pom.xml index 1666527..a1d4761 100644 --- a/beam/pom.xml +++ b/beam/pom.xml @@ -20,10 +20,10 @@ <modelVersion>4.0.0</modelVersion> <parent> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> - <relativePath>..</relativePath> + <relativePath>../interpreter-parent</relativePath> </parent> <groupId>org.apache.zeppelin</groupId> @@ -41,6 +41,7 @@ <netty.version>4.1.1.Final</netty.version> <servlet.api.version>3.1.0</servlet.api.version> <commons.exec.version>1.3</commons.exec.version> + <interpreter.name>beam</interpreter.name> </properties> <dependencies> @@ -240,69 +241,18 @@ </dependency> </dependencies> + <build> <plugins> - - <plugin> - <groupId>org.apache.maven.plugins</groupId> - <artifactId>maven-deploy-plugin</artifactId> - <configuration> - <skip>true</skip> - </configuration> - </plugin> - <plugin> <artifactId>maven-enforcer-plugin</artifactId> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> </plugin> - <plugin> <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/beam</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/beam</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> </plugin> - + <plugin> + <artifactId>maven-resources-plugin</artifactId> + </plugin> </plugins> </build> </project> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/bigquery/pom.xml ---------------------------------------------------------------------- diff --git a/bigquery/pom.xml b/bigquery/pom.xml index f974b98..db88eda 100644 --- a/bigquery/pom.xml +++ b/bigquery/pom.xml @@ -21,9 +21,10 @@ <modelVersion>4.0.0</modelVersion> <parent> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> + <relativePath>../interpreter-parent</relativePath> </parent> <groupId>org.apache.zeppelin</groupId> @@ -41,6 +42,7 @@ <!-- library versions --> <bigquery.api.version>v2-rev265-1.21.0</bigquery.api.version> <gson.version>2.6</gson.version> + <interpreter.name>bigquery</interpreter.name> </properties> <dependencies> @@ -99,12 +101,12 @@ <plugins> <plugin> <artifactId>maven-enforcer-plugin</artifactId> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> + </plugin> + <plugin> + <artifactId>maven-dependency-plugin</artifactId> + </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> </plugin> <plugin> @@ -116,63 +118,22 @@ </excludes> </configuration> </plugin> - <plugin> - <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/bqsql</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/bqsql</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> + <artifactId>maven-assembly-plugin</artifactId> + <configuration> + <archive> + <manifest> + <mainClass> + org.apache.zeppelin.bigquery.BigQueryInterpreter + </mainClass> + </manifest> + </archive> + <descriptorRefs> + <descriptorRef>jar-with-dependencies</descriptorRef> + </descriptorRefs> + </configuration> </plugin> - <plugin> - <artifactId>maven-assembly-plugin</artifactId> - <configuration> - <archive> - <manifest> - <mainClass> - org.apache.zeppelin.bigquery.BigQueryInterpreter - </mainClass> - </manifest> - </archive> - <descriptorRefs> - <descriptorRef>jar-with-dependencies</descriptorRef> - </descriptorRefs> - </configuration> - </plugin> </plugins> </build> + </project> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/cassandra/pom.xml ---------------------------------------------------------------------- diff --git a/cassandra/pom.xml b/cassandra/pom.xml index 05108e9..4b139e9 100644 --- a/cassandra/pom.xml +++ b/cassandra/pom.xml @@ -20,10 +20,10 @@ 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> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> - <relativePath>..</relativePath> + <relativePath>../interpreter-parent</relativePath> </parent> <groupId>org.apache.zeppelin</groupId> @@ -49,6 +49,7 @@ <plugin.scala.version>2.15.2</plugin.scala.version> <plugin.scalatest.version>1.0</plugin.scalatest.version> <plugin.scalate.version>1.7.1</plugin.scalate.version> + <interpreter.name>cassandra</interpreter.name> </properties> <dependencies> @@ -241,55 +242,14 @@ <plugin> <artifactId>maven-enforcer-plugin</artifactId> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> </plugin> - <plugin> <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/cassandra</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/cassandra</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> + </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> </plugin> </plugins> + </build> </project> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/docs/development/writing_zeppelin_interpreter.md ---------------------------------------------------------------------- diff --git a/docs/development/writing_zeppelin_interpreter.md b/docs/development/writing_zeppelin_interpreter.md index 6ba24bc..f4c0bc9 100644 --- a/docs/development/writing_zeppelin_interpreter.md +++ b/docs/development/writing_zeppelin_interpreter.md @@ -40,7 +40,49 @@ In 'Separate Interpreter(scoped / isolated) for each note' mode which you can se ## Make your own Interpreter Creating a new interpreter is quite simple. Just extend [org.apache.zeppelin.interpreter](https://github.com/apache/zeppelin/blob/master/zeppelin-interpreter/src/main/java/org/apache/zeppelin/interpreter/Interpreter.java) abstract class and implement some methods. -You can include `org.apache.zeppelin:zeppelin-interpreter:[VERSION]` artifact in your build system. And you should put your jars under your interpreter directory with a specific directory name. Zeppelin server reads interpreter directories recursively and initializes interpreters including your own interpreter. +For your interpreter project, you need to make `interpreter-parent` as your parent project and use plugin `maven-enforcer-plugin`, `maven-dependency-plugin` and `maven-resources-plugin`. Here's one sample pom.xml + +``` +<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> + <artifactId>interpreter-parent</artifactId> + <groupId>org.apache.zeppelin</groupId> + <version>0.8.0-SNAPSHOT</version> + <relativePath>../interpreter-parent</relativePath> + </parent> + + ... + + <dependencies> + <dependency> + <groupId>org.apache.zeppelin</groupId> + <artifactId>zeppelin-interpreter</artifactId> + <version>${project.version}</version> + <scope>provided</scope> + </dependency> + </dependencies> + + <build> + <plugins> + <plugin> + <artifactId>maven-enforcer-plugin</artifactId> + </plugin> + <plugin> + <artifactId>maven-dependency-plugin</artifactId> + </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> + </plugin> + </plugins> + </build> + +</project> +``` + +You should include `org.apache.zeppelin:zeppelin-interpreter:[VERSION]` as your interpreter's dependency in `pom.xml`. Bes +And you should put your jars under your interpreter directory with a specific directory name. Zeppelin server reads interpreter directories recursively and initializes interpreters including your own interpreter. There are three locations where you can store your interpreter group, name and other information. Zeppelin server tries to find the location below. Next, Zeppelin tries to find `interpreter-setting.json` in your interpreter jar. http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/elasticsearch/pom.xml ---------------------------------------------------------------------- diff --git a/elasticsearch/pom.xml b/elasticsearch/pom.xml index 6042a14..b317e28 100644 --- a/elasticsearch/pom.xml +++ b/elasticsearch/pom.xml @@ -20,10 +20,10 @@ <modelVersion>4.0.0</modelVersion> <parent> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> - <relativePath>..</relativePath> + <relativePath>../interpreter-parent</relativePath> </parent> <artifactId>zeppelin-elasticsearch</artifactId> @@ -32,6 +32,7 @@ <name>Zeppelin: Elasticsearch interpreter</name> <properties> + <interpreter.name>elasticsearch</interpreter.name> <elasticsearch.version>2.4.3</elasticsearch.version> <httpasyncclient.version>4.0.2</httpasyncclient.version> <guava.version>18.0</guava.version> @@ -93,54 +94,12 @@ <plugins> <plugin> <artifactId>maven-enforcer-plugin</artifactId> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> </plugin> - <plugin> <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/elasticsearch</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/elasticsearch</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> + </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> </plugin> </plugins> </build> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/file/pom.xml ---------------------------------------------------------------------- diff --git a/file/pom.xml b/file/pom.xml index 2493c1f..1a76683 100644 --- a/file/pom.xml +++ b/file/pom.xml @@ -20,9 +20,10 @@ <modelVersion>4.0.0</modelVersion> <parent> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> + <relativePath>../interpreter-parent</relativePath> </parent> <groupId>org.apache.zeppelin</groupId> @@ -33,11 +34,13 @@ <properties> <!--library versions--> + <interpreter.name>file</interpreter.name> <ws.rsapi.version>2.0</ws.rsapi.version> <jersey.common.version>2.22.2</jersey.common.version> <!--plugin versions--> <plugin.surefire.version>2.18.1</plugin.surefire.version> + <interpreter.name>file</interpreter.name> </properties> <dependencies> @@ -80,61 +83,13 @@ <build> <plugins> <plugin> - <groupId>org.apache.maven.plugins</groupId> - <artifactId>maven-surefire-plugin</artifactId> - <version>${plugin.surefire.version}</version> - </plugin> - - <plugin> <artifactId>maven-enforcer-plugin</artifactId> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> </plugin> - <plugin> <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/file</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/file</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <!--<includeScope>runtime</includeScope>--> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> + </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> </plugin> </plugins> </build> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/flink/pom.xml ---------------------------------------------------------------------- diff --git a/flink/pom.xml b/flink/pom.xml index 19e7c5e..5c0cc3b 100644 --- a/flink/pom.xml +++ b/flink/pom.xml @@ -20,10 +20,10 @@ <modelVersion>4.0.0</modelVersion> <parent> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> - <relativePath>..</relativePath> + <relativePath>../interpreter-parent</relativePath> </parent> <groupId>org.apache.zeppelin</groupId> @@ -35,6 +35,7 @@ <properties> <!--library versions--> + <interpreter.name>flink</interpreter.name> <flink.version>1.1.3</flink.version> <flink.akka.version>2.3.7</flink.akka.version> <scala.macros.version>2.0.1</scala.macros.version> @@ -280,68 +281,16 @@ </configuration> </plugin> - <plugin> - <artifactId>maven-enforcer-plugin</artifactId> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> - </plugin> + <plugin> + <artifactId>maven-enforcer-plugin</artifactId> + </plugin> + <plugin> + <artifactId>maven-dependency-plugin</artifactId> + </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> + </plugin> - <plugin> - <groupId>org.apache.maven.plugins</groupId> - <artifactId>maven-surefire-plugin</artifactId> - <configuration> - <forkCount>1</forkCount> - <reuseForks>false</reuseForks> - <argLine>-Xmx1024m -XX:MaxPermSize=256m</argLine> - </configuration> - </plugin> - - <plugin> - <groupId>org.apache.maven.plugins</groupId> - <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/flink</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/flink</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> - </plugin> </plugins> </build> </project> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/geode/pom.xml ---------------------------------------------------------------------- diff --git a/geode/pom.xml b/geode/pom.xml index e8eb9fc..4a9dadd 100644 --- a/geode/pom.xml +++ b/geode/pom.xml @@ -21,9 +21,10 @@ <modelVersion>4.0.0</modelVersion> <parent> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> + <relativePath>../interpreter-parent</relativePath> </parent> <groupId>org.apache.zeppelin</groupId> @@ -34,6 +35,7 @@ <properties> <!--library versions--> + <interpreter.name>geode</interpreter.name> <geode.version>1.1.0</geode.version> <commons.exec.version>1.3</commons.exec.version> </properties> @@ -86,54 +88,12 @@ <plugins> <plugin> <artifactId>maven-enforcer-plugin</artifactId> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> </plugin> - <plugin> <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/geode</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/geode</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> + </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> </plugin> </plugins> </build> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/groovy/pom.xml ---------------------------------------------------------------------- diff --git a/groovy/pom.xml b/groovy/pom.xml index bee50bd..64c51f8 100644 --- a/groovy/pom.xml +++ b/groovy/pom.xml @@ -20,11 +20,11 @@ <modelVersion>4.0.0</modelVersion> <parent> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <!--version>0.6.2</version--> <version>0.8.0-SNAPSHOT</version> - <relativePath>..</relativePath> + <relativePath>../interpreter-parent</relativePath> </parent> <groupId>org.apache.zeppelin</groupId> @@ -33,6 +33,10 @@ <version>0.8.0-SNAPSHOT</version> <name>Zeppelin: Groovy interpreter</name> + <properties> + <interpreter.name>groovy</interpreter.name> + </properties> + <dependencies> <dependency> <groupId>${project.groupId}</groupId> @@ -68,80 +72,13 @@ <build> <plugins> <plugin> - <groupId>org.apache.maven.plugins</groupId> - <artifactId>maven-compiler-plugin</artifactId> - <version>3.1</version> - <configuration> - <showDeprecation>true</showDeprecation> - <compilerArgs> - <!--arg>-verbose</arg--> - <arg>-Xlint:unchecked</arg> - </compilerArgs> - </configuration> - </plugin> - - <!--TODO: comment local `maven-checkstyle-plugin` and use zeppelin common check style--> - <plugin> - <groupId>org.apache.maven.plugins</groupId> - <artifactId>maven-checkstyle-plugin</artifactId> - <configuration> - <skip>true</skip> - </configuration> - <executions> - </executions> - </plugin> - <plugin> <artifactId>maven-enforcer-plugin</artifactId> - <version>1.3.1</version> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> </plugin> - <plugin> <artifactId>maven-dependency-plugin</artifactId> - <version>2.8</version> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/groovy</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/groovy</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> + </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> </plugin> </plugins> </build> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/groovy/src/main/java/org/apache/zeppelin/groovy/GObject.java ---------------------------------------------------------------------- diff --git a/groovy/src/main/java/org/apache/zeppelin/groovy/GObject.java b/groovy/src/main/java/org/apache/zeppelin/groovy/GObject.java index 7f6809a..ce7d00f 100644 --- a/groovy/src/main/java/org/apache/zeppelin/groovy/GObject.java +++ b/groovy/src/main/java/org/apache/zeppelin/groovy/GObject.java @@ -172,7 +172,7 @@ public class GObject extends groovy.lang.GroovyObjectSupport { /** * starts or continues rendering html/angular and returns MarkupBuilder to build html. * <pre> g.html().with{ - * h1("hello") + * h1("hello") * h2("world") * }</pre> */ http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/groovy/src/main/java/org/apache/zeppelin/groovy/GroovyInterpreter.java ---------------------------------------------------------------------- diff --git a/groovy/src/main/java/org/apache/zeppelin/groovy/GroovyInterpreter.java b/groovy/src/main/java/org/apache/zeppelin/groovy/GroovyInterpreter.java index e108283..8c83ef7 100644 --- a/groovy/src/main/java/org/apache/zeppelin/groovy/GroovyInterpreter.java +++ b/groovy/src/main/java/org/apache/zeppelin/groovy/GroovyInterpreter.java @@ -204,7 +204,7 @@ public class GroovyInterpreter extends Interpreter { Thread t = (Thread) object; t.dumpStack(); t.interrupt(); - //t.stop(); //TODO: need some way to terminate maybe through GObject.. + //t.stop(); //TODO(dlukyanov): need some way to terminate maybe through GObject.. } catch (Throwable t) { log.error("Failed to cancel script: " + t, t); } http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/hbase/pom.xml ---------------------------------------------------------------------- diff --git a/hbase/pom.xml b/hbase/pom.xml index 08b0cd7..8f27631 100644 --- a/hbase/pom.xml +++ b/hbase/pom.xml @@ -20,9 +20,10 @@ 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> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> + <relativePath>../interpreter-parent</relativePath> </parent> <groupId>org.apache.zeppelin</groupId> @@ -33,6 +34,7 @@ <properties> <!--library versions--> + <interpreter.name>hbase</interpreter.name> <hbase.hbase.version>1.0.0</hbase.hbase.version> <hbase.hadoop.version>2.6.0</hbase.hadoop.version> <jruby.version>1.6.8</jruby.version> @@ -115,55 +117,14 @@ <plugins> <plugin> <artifactId>maven-enforcer-plugin</artifactId> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> </plugin> - <plugin> <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/hbase</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/hbase</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> + </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> </plugin> </plugins> </build> + </project> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/helium-dev/pom.xml ---------------------------------------------------------------------- diff --git a/helium-dev/pom.xml b/helium-dev/pom.xml index 77c4dee..8514946 100644 --- a/helium-dev/pom.xml +++ b/helium-dev/pom.xml @@ -23,8 +23,9 @@ <parent> <groupId>org.apache.zeppelin</groupId> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <version>0.8.0-SNAPSHOT</version> + <relativePath>../interpreter-parent</relativePath> </parent> <groupId>org.apache.zeppelin</groupId> @@ -32,6 +33,10 @@ <version>0.8.0-SNAPSHOT</version> <name>Zeppelin: Helium development interpreter</name> + <properties> + <interpreter.name>helium-dev</interpreter.name> + </properties> + <dependencies> <dependency> <groupId>org.apache.zeppelin</groupId> @@ -44,45 +49,13 @@ <build> <plugins> <plugin> + <artifactId>maven-enforcer-plugin</artifactId> + </plugin> + <plugin> <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/helium-dev</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/helium-dev</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> + </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> </plugin> </plugins> </build> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/ignite/pom.xml ---------------------------------------------------------------------- diff --git a/ignite/pom.xml b/ignite/pom.xml index 9b1855c..ccbd37d 100644 --- a/ignite/pom.xml +++ b/ignite/pom.xml @@ -20,10 +20,10 @@ <modelVersion>4.0.0</modelVersion> <parent> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> - <relativePath>..</relativePath> + <relativePath>../interpreter-parent</relativePath> </parent> <artifactId>zeppelin-ignite_2.10</artifactId> @@ -32,6 +32,7 @@ <name>Zeppelin: Apache Ignite interpreter</name> <properties> + <interpreter.name>ignite</interpreter.name> <ignite.version>2.2.0</ignite.version> </properties> @@ -106,55 +107,12 @@ <plugins> <plugin> <artifactId>maven-enforcer-plugin</artifactId> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> </plugin> - <plugin> - <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/ignite</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/ignite</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> + </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> </plugin> </plugins> </build> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/interpreter-parent/pom.xml ---------------------------------------------------------------------- diff --git a/interpreter-parent/pom.xml b/interpreter-parent/pom.xml new file mode 100644 index 0000000..32bdc57 --- /dev/null +++ b/interpreter-parent/pom.xml @@ -0,0 +1,138 @@ +<?xml version="1.0" encoding="UTF-8"?> +<!-- + ~ 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> + <artifactId>zeppelin</artifactId> + <groupId>org.apache.zeppelin</groupId> + <version>0.8.0-SNAPSHOT</version> + <relativePath>..</relativePath> + </parent> + + <groupId>org.apache.zeppelin</groupId> + <artifactId>interpreter-parent</artifactId> + <packaging>pom</packaging> + <version>0.8.0-SNAPSHOT</version> + <name>Zeppelin: Interpreter Parent</name> + + <dependencyManagement> + <dependencies> + <dependency> + <groupId>${project.groupId}</groupId> + <artifactId>zeppelin-interpreter</artifactId> + <version>0.8.0-SNAPSHOT</version> + <scope>provided</scope> + </dependency> + + <dependency> + <groupId>junit</groupId> + <artifactId>junit</artifactId> + <version>${junit.version}</version> + <scope>test</scope> + </dependency> + + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-api</artifactId> + <version>${slf4j.version}</version> + </dependency> + + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-log4j12</artifactId> + <version>${slf4j.version}</version> + </dependency> + </dependencies> + </dependencyManagement> + + <build> + <pluginManagement> + <plugins> + <plugin> + <artifactId>maven-enforcer-plugin</artifactId> + <executions> + <execution> + <id>enforce</id> + <phase>none</phase> + </execution> + </executions> + </plugin> + + <plugin> + <artifactId>maven-dependency-plugin</artifactId> + <executions> + <execution> + <id>copy-interpreter-dependencies</id> + <phase>package</phase> + <goals> + <goal>copy-dependencies</goal> + </goals> + <configuration> + <outputDirectory>${project.build.directory}/../../interpreter/${interpreter.name}</outputDirectory> + <overWriteReleases>false</overWriteReleases> + <overWriteSnapshots>false</overWriteSnapshots> + <overWriteIfNewer>true</overWriteIfNewer> + <includeScope>runtime</includeScope> + </configuration> + </execution> + <execution> + <id>copy-artifact</id> + <phase>package</phase> + <goals> + <goal>copy</goal> + </goals> + <configuration> + <outputDirectory>${project.build.directory}/../../interpreter/${interpreter.name}</outputDirectory> + <overWriteReleases>false</overWriteReleases> + <overWriteSnapshots>false</overWriteSnapshots> + <overWriteIfNewer>true</overWriteIfNewer> + <artifactItems> + <artifactItem> + <groupId>${project.groupId}</groupId> + <artifactId>${project.artifactId}</artifactId> + <version>${project.version}</version> + <type>${project.packaging}</type> + </artifactItem> + </artifactItems> + </configuration> + </execution> + </executions> + </plugin> + + <plugin> + <artifactId>maven-resources-plugin</artifactId> + <executions> + <execution> + <id>copy-interpreter-setting</id> + <phase>package</phase> + <goals> + <goal>resources</goal> + </goals> + <configuration> + <outputDirectory>${project.build.directory}/../../interpreter/${interpreter.name}</outputDirectory> + </configuration> + </execution> + </executions> + </plugin> + </plugins> + </pluginManagement> + </build> + +</project> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/jdbc/pom.xml ---------------------------------------------------------------------- diff --git a/jdbc/pom.xml b/jdbc/pom.xml index 71d3310..beec50c 100644 --- a/jdbc/pom.xml +++ b/jdbc/pom.xml @@ -21,9 +21,10 @@ <modelVersion>4.0.0</modelVersion> <parent> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> + <relativePath>../interpreter-parent</relativePath> </parent> <groupId>org.apache.zeppelin</groupId> @@ -34,6 +35,7 @@ <properties> <!--library versions--> + <interpreter.name>jdbc</interpreter.name> <postgresql.version>9.4-1201-jdbc41</postgresql.version> <hadoop.common.version>2.7.2</hadoop.common.version> <h2.version>1.4.190</h2.version> @@ -158,54 +160,12 @@ <plugins> <plugin> <artifactId>maven-enforcer-plugin</artifactId> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> </plugin> - <plugin> <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/jdbc</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/jdbc</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> + </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> </plugin> </plugins> </build> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/kylin/pom.xml ---------------------------------------------------------------------- diff --git a/kylin/pom.xml b/kylin/pom.xml index c3559cd..b70facb 100644 --- a/kylin/pom.xml +++ b/kylin/pom.xml @@ -21,9 +21,10 @@ 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"> <parent> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> + <relativePath>../interpreter-parent</relativePath> </parent> <modelVersion>4.0.0</modelVersion> @@ -33,6 +34,10 @@ <version>0.8.0-SNAPSHOT</version> <name>Zeppelin: Kylin interpreter</name> + <properties> + <interpreter.name>kylin</interpreter.name> + </properties> + <dependencies> <dependency> @@ -61,57 +66,14 @@ <plugins> <plugin> <artifactId>maven-enforcer-plugin</artifactId> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> </plugin> - <plugin> <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/kylin</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/kylin</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> + </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> </plugin> </plugins> </build> - </project> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/lens/pom.xml ---------------------------------------------------------------------- diff --git a/lens/pom.xml b/lens/pom.xml index 0328355..ecc0a12 100644 --- a/lens/pom.xml +++ b/lens/pom.xml @@ -20,10 +20,10 @@ <modelVersion>4.0.0</modelVersion> <parent> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> - <relativePath>..</relativePath> + <relativePath>../interpreter-parent</relativePath> </parent> <groupId>org.apache.zeppelin</groupId> @@ -34,6 +34,7 @@ <properties> <!--library versions--> + <interpreter.name>lens</interpreter.name> <lens.version>2.5.0-beta</lens.version> <spring-shell.version>1.1.0.RELEASE</spring-shell.version> <hadoop-common.version>2.4.0</hadoop-common.version> @@ -163,69 +164,13 @@ <plugins> <plugin> <artifactId>maven-enforcer-plugin</artifactId> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> </plugin> - <plugin> <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/lens</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/lens</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> </plugin> - - <plugin> - <groupId>org.apache.maven.plugins</groupId> - <artifactId>maven-clean-plugin</artifactId> - <configuration> - <filesets> - <fileset> - <directory>${basedir}/../interpreter/lens</directory> - <followSymlinks>false</followSymlinks> - </fileset> - </filesets> - </configuration> - </plugin> - + <plugin> + <artifactId>maven-resources-plugin</artifactId> + </plugin> </plugins> </build> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/livy/pom.xml ---------------------------------------------------------------------- diff --git a/livy/pom.xml b/livy/pom.xml index e7217fb..0ec174a 100644 --- a/livy/pom.xml +++ b/livy/pom.xml @@ -22,10 +22,10 @@ <modelVersion>4.0.0</modelVersion> <parent> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> - <relativePath>..</relativePath> + <relativePath>../interpreter-parent</relativePath> </parent> <groupId>org.apache.zeppelin</groupId> @@ -36,6 +36,7 @@ <properties> <!--library versions--> + <interpreter.name>livy</interpreter.name> <commons.exec.version>1.3</commons.exec.version> <spring.web.version>4.3.0.RELEASE</spring.web.version> <spring.security.kerberosclient>1.0.1.RELEASE</spring.security.kerberosclient> @@ -193,56 +194,12 @@ <plugins> <plugin> <artifactId>maven-enforcer-plugin</artifactId> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> </plugin> - <plugin> <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/livy - </outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/livy - </outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> + </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> </plugin> <plugin> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/markdown/pom.xml ---------------------------------------------------------------------- diff --git a/markdown/pom.xml b/markdown/pom.xml index 9675aa7..ca95449 100644 --- a/markdown/pom.xml +++ b/markdown/pom.xml @@ -20,10 +20,10 @@ <modelVersion>4.0.0</modelVersion> <parent> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> - <relativePath>..</relativePath> + <relativePath>../interpreter-parent</relativePath> </parent> <groupId>org.apache.zeppelin</groupId> @@ -33,6 +33,7 @@ <name>Zeppelin: Markdown interpreter</name> <properties> + <interpreter.name>md</interpreter.name> <commons.lang3.version>3.4</commons.lang3.version> <markdown4j.version>2.2-cj-1.0</markdown4j.version> <pegdown.version>1.6.0</pegdown.version> @@ -85,54 +86,12 @@ <plugins> <plugin> <artifactId>maven-enforcer-plugin</artifactId> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> </plugin> - <plugin> <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/md</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/md</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> + </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> </plugin> </plugins> </build> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/pig/pom.xml ---------------------------------------------------------------------- diff --git a/pig/pom.xml b/pig/pom.xml index f76a3f9..4a56a34 100644 --- a/pig/pom.xml +++ b/pig/pom.xml @@ -22,9 +22,10 @@ <modelVersion>4.0.0</modelVersion> <parent> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> + <relativePath>../interpreter-parent</relativePath> </parent> <groupId>org.apache.zeppelin</groupId> @@ -36,6 +37,7 @@ <url>http://zeppelin.apache.org</url> <properties> + <interpreter.name>pig</interpreter.name> <pig.version>0.17.0</pig.version> <hadoop.version>2.6.0</hadoop.version> <tez.version>0.7.0</tez.version> @@ -175,58 +177,13 @@ <plugins> <plugin> <artifactId>maven-enforcer-plugin</artifactId> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> </plugin> - <plugin> <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/pig - </outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/pig - </outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> </plugin> - + <plugin> + <artifactId>maven-resources-plugin</artifactId> + </plugin> <plugin> <artifactId>maven-surefire-plugin</artifactId> <configuration> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/python/pom.xml ---------------------------------------------------------------------- diff --git a/python/pom.xml b/python/pom.xml index d46cd10..a906b5d 100644 --- a/python/pom.xml +++ b/python/pom.xml @@ -20,10 +20,10 @@ <modelVersion>4.0.0</modelVersion> <parent> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> - <relativePath>..</relativePath> + <relativePath>../interpreter-parent</relativePath> </parent> <groupId>org.apache.zeppelin</groupId> @@ -33,6 +33,7 @@ <name>Zeppelin: Python interpreter</name> <properties> + <interpreter.name>python</interpreter.name> <python.py4j.version>0.9.2</python.py4j.version> <python.test.exclude> **/PythonInterpreterWithPythonInstalledTest.java, @@ -142,17 +143,6 @@ </plugin> <plugin> - <artifactId>maven-enforcer-plugin</artifactId> - <version>1.3.1</version> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> - </plugin> - - <plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>wagon-maven-plugin</artifactId> <version>1.0</version> @@ -213,46 +203,13 @@ </plugin> <plugin> + <artifactId>maven-enforcer-plugin</artifactId> + </plugin> + <plugin> <artifactId>maven-dependency-plugin</artifactId> - <version>2.8</version> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/python</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/python</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> + </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> </plugin> </plugins> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/scalding/pom.xml ---------------------------------------------------------------------- diff --git a/scalding/pom.xml b/scalding/pom.xml index cc1015f..763afe0 100644 --- a/scalding/pom.xml +++ b/scalding/pom.xml @@ -20,10 +20,10 @@ <modelVersion>4.0.0</modelVersion> <parent> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> - <relativePath>..</relativePath> + <relativePath>../interpreter-parent</relativePath> </parent> <groupId>org.apache.zeppelin</groupId> @@ -33,6 +33,7 @@ <name>Zeppelin: Scalding interpreter</name> <properties> + <interpreter.name>scalding</interpreter.name> <!--library versions--> <hadoop.version>2.6.0</hadoop.version> <scalding.version>0.16.1-RC1</scalding.version> @@ -147,55 +148,14 @@ <plugins> <plugin> <artifactId>maven-enforcer-plugin</artifactId> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> </plugin> - <plugin> <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <id>copy-dependencies</id> - <phase>package</phase> - <goals> - <goal>copy-dependencies</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/scalding</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - </configuration> - </execution> - <execution> - <id>copy-artifact</id> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/scalding</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> + </plugin> + <!-- Plugin to compile Scala code --> <plugin> <groupId>org.scala-tools</groupId> http://git-wip-us.apache.org/repos/asf/zeppelin/blob/4a3057fa/scio/pom.xml ---------------------------------------------------------------------- diff --git a/scio/pom.xml b/scio/pom.xml index 3d17dc8..27ccb0c 100644 --- a/scio/pom.xml +++ b/scio/pom.xml @@ -20,10 +20,10 @@ <modelVersion>4.0.0</modelVersion> <parent> - <artifactId>zeppelin</artifactId> + <artifactId>interpreter-parent</artifactId> <groupId>org.apache.zeppelin</groupId> <version>0.8.0-SNAPSHOT</version> - <relativePath>..</relativePath> + <relativePath>../interpreter-parent</relativePath> </parent> <groupId>org.apache.zeppelin</groupId> @@ -34,6 +34,7 @@ <description>Zeppelin Scio support</description> <properties> + <interpreter.name>scio</interpreter.name> <!--library versions--> <scio.version>0.2.4</scio.version> <guava.version>14.0.1</guava.version> <!-- update needed --> @@ -106,12 +107,12 @@ <plugins> <plugin> <artifactId>maven-enforcer-plugin</artifactId> - <executions> - <execution> - <id>enforce</id> - <phase>none</phase> - </execution> - </executions> + </plugin> + <plugin> + <artifactId>maven-dependency-plugin</artifactId> + </plugin> + <plugin> + <artifactId>maven-resources-plugin</artifactId> </plugin> <plugin> @@ -157,34 +158,6 @@ </plugin> <plugin> - <groupId>org.apache.maven.plugins</groupId> - <artifactId>maven-dependency-plugin</artifactId> - <executions> - <execution> - <phase>package</phase> - <goals> - <goal>copy</goal> - </goals> - <configuration> - <outputDirectory>${project.build.directory}/../../interpreter/scio</outputDirectory> - <overWriteReleases>false</overWriteReleases> - <overWriteSnapshots>false</overWriteSnapshots> - <overWriteIfNewer>true</overWriteIfNewer> - <includeScope>runtime</includeScope> - <artifactItems> - <artifactItem> - <groupId>${project.groupId}</groupId> - <artifactId>${project.artifactId}</artifactId> - <version>${project.version}</version> - <type>${project.packaging}</type> - </artifactItem> - </artifactItems> - </configuration> - </execution> - </executions> - </plugin> - - <plugin> <groupId>org.scala-tools</groupId> <artifactId>maven-scala-plugin</artifactId> <version>${plugin.scala.version}</version>