Repository: zeppelin Updated Branches: refs/heads/master b7c3fec95 -> a19ec6711
[ZEPPELIN-3528] Ordering by interpreter name in same interpreter group ### What is this PR for? In 'Create new note' diagram, 'Default Interpreter' is ordered by only interpreter groups. But interpreter is not ordered in same interpreter group. (It seems to be ordered by hashcode of 'InterpreterSetting') When there are many interpreter in same group and this group is first, user cannot predict what interpreter is showed first. So I think that interpreter need to be ordered by name. ### What type of PR is it? [Improvement] ### Todos * [x] - Modify Code ### What is the Jira issue? * https://issues.apache.org/jira/browse/ZEPPELIN-3528 ### How should this be tested? * Click 'create new note' ### 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: Jaehoon Jeong <jaehoon.je...@woowahan.com> Closes #3005 from woowahan-jaehoon/ZEPPELIN-3528 and squashes the following commits: 5cb709ce3 [Jaehoon Jeong] [ZEPPELIN-3528] Ordering by interpreter name in same interpreter group Project: http://git-wip-us.apache.org/repos/asf/zeppelin/repo Commit: http://git-wip-us.apache.org/repos/asf/zeppelin/commit/a19ec671 Tree: http://git-wip-us.apache.org/repos/asf/zeppelin/tree/a19ec671 Diff: http://git-wip-us.apache.org/repos/asf/zeppelin/diff/a19ec671 Branch: refs/heads/master Commit: a19ec671123283c1ec3c49b2514e9d0777da4889 Parents: b7c3fec Author: Jaehoon Jeong <jaehoon.je...@woowahan.com> Authored: Tue Jun 5 20:39:55 2018 +0900 Committer: Jeff Zhang <zjf...@apache.org> Committed: Thu Jun 14 11:10:03 2018 +0800 ---------------------------------------------------------------------- .../org/apache/zeppelin/interpreter/InterpreterSettingManager.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/zeppelin/blob/a19ec671/zeppelin-zengine/src/main/java/org/apache/zeppelin/interpreter/InterpreterSettingManager.java ---------------------------------------------------------------------- diff --git a/zeppelin-zengine/src/main/java/org/apache/zeppelin/interpreter/InterpreterSettingManager.java b/zeppelin-zengine/src/main/java/org/apache/zeppelin/interpreter/InterpreterSettingManager.java index d595a5d..4d86588 100644 --- a/zeppelin-zengine/src/main/java/org/apache/zeppelin/interpreter/InterpreterSettingManager.java +++ b/zeppelin-zengine/src/main/java/org/apache/zeppelin/interpreter/InterpreterSettingManager.java @@ -917,7 +917,7 @@ public class InterpreterSettingManager implements InterpreterSettingManagerMBean } else if (i > j) { return 1; } else { - return 0; + return o1.getName().compareTo(o2.getName()); } } });