GitHub user cloverhearts reopened a pull request:

    https://github.com/apache/zeppelin/pull/908

    ZEPPELIN-598 ] Dynamic loading for Interpreter and API

    ### What is this PR for?
    Use of external libraries that are included in the Roadmap,
    The interpreter needs related to dynamic loading capabilities.
    
    
    ### What type of PR is it?
    Feature
    
    ### Todos
    * [x] - Dynamic load
    * [x] - make api
    * [x] - Modified according to feedback 
(https://github.com/apache/incubator-zeppelin/pull/631)
    
    ### ScreenShots
    
![markdown_test](https://cloud.githubusercontent.com/assets/10525473/15452508/d786f276-202b-11e6-95e5-0e2b898cb6c7.gif)
    
    
    ### Is there a relevant Jira issue?
    https://issues.apache.org/jira/browse/ZEPPELIN-598
    
    ### How should this be tested?
    By annotating the interpreter setting items below, try using the 
loadDynamicInterpreter method.
    Or create a new interpreter loads created in the local Maven repository.
    
    Step 1.
    markdown interpreter to local distribute
    ```
    mvn install -pl 
'!spark-dependencies,!spark,!flink,!ignite,!lens,!hive,!phoenix,!postgresql,!tajo,!cassandra,!kylin,!elasticsearch,!zeppelin-distribution'
 -DskipTests
    ```
    Step 2.
    Comment out the markdown
    
incubator-zeppelin/zeppelin-zengine/src/main/java/org/apache/zeppelin/conf/ZeppelinConfiguration.java
    ``` java 
        ZEPPELIN_INTERPRETERS("zeppelin.interpreters", 
"org.apache.zeppelin.spark.SparkInterpreter,"
            + "org.apache.zeppelin.spark.PySparkInterpreter,"
            + "org.apache.zeppelin.spark.SparkSqlInterpreter,"
            + "org.apache.zeppelin.spark.DepInterpreter,"
            // + "org.apache.zeppelin.markdown.Markdown,"
    ...
    ```
    Step 3.
    and build.
    For example.
    ```
    mvn clean package -Pspark-1.6 -Phadoop-2.4 -Pyarn -Ppyspark -DskipTests
    ```
    Step 4.
    remove to interpreter/md
    ```
    rm -rf interpreter/md
    ```
    option.
    fixed conf/zeppelin-env.sh(cmd) download interpreter directory.
    ```
    export ZEPPELIN_INTERPRETER_DOWNLOAD_DIR=MyZeppelinInterpreter
    ```
    Step 5.
    and API Call (load interpreter) example load markdown 
    ```
    Content-Type: application/json
    ```
    
    ```
    POST http://127.0.0.1:8080/api/interpreter/load/md/markdown
    {
      "artifact": 
"org.apache.zeppelin:zeppelin-markdown:0.6.0-incubating-SNAPSHOT",
      "className": "org.apache.zeppelin.markdown.Markdown",
      "repository": {
        "url": "http://dl.bintray.com/spark-packages/maven";,
        "snapshot" : true
      }
    }
    ```
    
    Step 6. 
    In interperter menu for zeppelin web, you can new setting information for 
md.
    
    ### Questions:
    * Does the licenses files need update? no
    * Is there breaking changes for older versions? no
    * Does this needs documentation? **no**

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/cloverhearts/zeppelin feat/ZEPPELIN-598

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/zeppelin/pull/908.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #908
    
----
commit 3d0a9d4c3781dce264b186aa862d8dddeb52518d
Author: CloverHearts <[email protected]>
Date:   2016-05-22T05:42:48Z

    Implement feat. dynamic load interpreter class

commit 599639fb0ced60e26807e9f771fe8f127945596c
Author: CloverHearts <[email protected]>
Date:   2016-05-23T05:17:49Z

    fixed invalid result for dynamic interpreter

commit 1b598b7c0ba52d8a2a639ea65d735d92b6486f5c
Author: CloverHearts <[email protected]>
Date:   2016-06-04T14:47:27Z

    Merge branch 'master' into feat/ZEPPELIN-598
    
    Conflicts:
        conf/zeppelin-env.cmd.template
        conf/zeppelin-env.sh.template

commit 3965f740787a7acd5a6219c5228fa3fdc2109c76
Author: CloverHearts <[email protected]>
Date:   2016-06-04T13:49:52Z

    add config in zeppelin env - dynamic interperter

commit 1bb3a0c138e38e602ed487fa59075c557687df62
Author: CloverHearts <[email protected]>
Date:   2016-06-04T14:05:46Z

    add path for interpreter download path at doc/install/install.md

commit 377393aad7a36c919b8f86875f7aac30708e14ab
Author: CloverHearts <[email protected]>
Date:   2016-06-04T14:23:25Z

    add interpreter download dir for zeppelin-site.xml.template

commit 43ad199a348f009915891d133dc832e10d700a03
Author: CloverHearts <[email protected]>
Date:   2016-06-08T02:20:06Z

    Merge branch 'master' into feat/ZEPPELIN-598

commit 04d84d30ff57cb2c8d1c63e95233e2ffa3eae4f8
Author: CloverHearts <[email protected]>
Date:   2016-06-09T05:53:55Z

    add exception for dynamic loading

commit b10b64d557ab68cda8ce352be16bd8740117fd15
Author: CloverHearts <[email protected]>
Date:   2016-06-09T07:19:21Z

    Merge branch 'master' into feat/ZEPPELIN-598

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to