zeppelin-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jongy...@apache.org
Subject zeppelin git commit: ZEPPELIN-2083: default interpreter list should honour order of zeppelin.interpreters property in zeppelin-site.xml
Date Fri, 10 Feb 2017 05:10:52 GMT
Repository: zeppelin
Updated Branches:
  refs/heads/master b8600a630 -> 72f62c4c3


ZEPPELIN-2083: default interpreter list should honour order of zeppelin.interpreters property
in zeppelin-site.xml

### What is this PR for?
Default interpreter list should honour order of zeppelin.interpreters property in zeppelin-site.xml

### What type of PR is it?
[Bug Fix]

### What is the Jira issue?
* [ZEPPELIN-2083](https://issues.apache.org/jira/browse/ZEPPELIN-2083)

### How should this be tested?
Remove default spark interpreter, and and another with a different name say "spark2". This
newly created interpreter should show up on top.

### Screenshots (if appropriate)

Before:
<img width="1439" alt="screen shot 2017-02-08 at 6 58 09 pm" src="https://cloud.githubusercontent.com/assets/674497/22739380/66c50e72-ee31-11e6-83cc-07669d292a12.png">

After:
<img width="1434" alt="screen shot 2017-02-08 at 6 56 42 pm" src="https://cloud.githubusercontent.com/assets/674497/22739379/66c377d8-ee31-11e6-965c-f9f61b288d99.png">

### Questions:
* Does the licenses files need update? N/A
* Is there breaking changes for older versions? N/A
* Does this needs documentation? N/A

Author: Prabhjyot Singh <prabhjyotsingh@gmail.com>

Closes #1992 from prabhjyotsingh/ZEPPELIN-2053 and squashes the following commits:

b17d9bd [Prabhjyot Singh] ZEPPELIN-2053: default interpreter list should honour order of zeppelin.interpreters
property in zeppelin-site.xml


Project: http://git-wip-us.apache.org/repos/asf/zeppelin/repo
Commit: http://git-wip-us.apache.org/repos/asf/zeppelin/commit/72f62c4c
Tree: http://git-wip-us.apache.org/repos/asf/zeppelin/tree/72f62c4c
Diff: http://git-wip-us.apache.org/repos/asf/zeppelin/diff/72f62c4c

Branch: refs/heads/master
Commit: 72f62c4c361db154f085570a91c1c9cb02a83ac3
Parents: b8600a6
Author: Prabhjyot Singh <prabhjyotsingh@gmail.com>
Authored: Wed Feb 8 19:03:01 2017 +0530
Committer: Jongyoul Lee <jongyoul@apache.org>
Committed: Fri Feb 10 14:10:45 2017 +0900

----------------------------------------------------------------------
 .../org/apache/zeppelin/interpreter/InterpreterFactory.java  | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/zeppelin/blob/72f62c4c/zeppelin-zengine/src/main/java/org/apache/zeppelin/interpreter/InterpreterFactory.java
----------------------------------------------------------------------
diff --git a/zeppelin-zengine/src/main/java/org/apache/zeppelin/interpreter/InterpreterFactory.java
b/zeppelin-zengine/src/main/java/org/apache/zeppelin/interpreter/InterpreterFactory.java
index 633a9b1..0342f76 100644
--- a/zeppelin-zengine/src/main/java/org/apache/zeppelin/interpreter/InterpreterFactory.java
+++ b/zeppelin-zengine/src/main/java/org/apache/zeppelin/interpreter/InterpreterFactory.java
@@ -843,11 +843,11 @@ public class InterpreterFactory implements InterpreterGroupFactory {
 
       Map<String, List<InterpreterSetting>> nameInterpreterSettingMap = new HashMap<>();
       for (InterpreterSetting interpreterSetting : interpreterSettings.values()) {
-        String name = interpreterSetting.getName();
-        if (!nameInterpreterSettingMap.containsKey(name)) {
-          nameInterpreterSettingMap.put(name, new ArrayList<InterpreterSetting>());
+        String group = interpreterSetting.getGroup();
+        if (!nameInterpreterSettingMap.containsKey(group)) {
+          nameInterpreterSettingMap.put(group, new ArrayList<InterpreterSetting>());
         }
-        nameInterpreterSettingMap.get(name).add(interpreterSetting);
+        nameInterpreterSettingMap.get(group).add(interpreterSetting);
       }
 
       for (String groupName : interpreterGroupOrderList) {


Mime
View raw message