You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@zeppelin.apache.org by jo...@apache.org on 2018/04/05 08:09:34 UTC
zeppelin git commit: [HOTFIX] Fix ClassCastException when reading
interpreter.json
Repository: zeppelin
Updated Branches:
refs/heads/master 1add74b4b -> 881846364
[HOTFIX] Fix ClassCastException when reading interpreter.json
### What is this PR for?
Fix the bug reported in https://github.com/apache/zeppelin/commit/b49b3f46f91d06c4d497f8f11cbc334fd480e539#commitcomment-28397460
### What type of PR is it?
[Hot Fix ]
### Todos
* [ ] - Task
### What is the Jira issue?
* NO Jira created
### How should this be tested?
* CI pass
### 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 <zj...@apache.org>
Closes #2908 from zjffdu/HOTFIX_MASTER and squashes the following commits:
5f1dc41d9 [Jeff Zhang] [HOTFIX] Fix ClassCastException when reading interpreter.json
Project: http://git-wip-us.apache.org/repos/asf/zeppelin/repo
Commit: http://git-wip-us.apache.org/repos/asf/zeppelin/commit/88184636
Tree: http://git-wip-us.apache.org/repos/asf/zeppelin/tree/88184636
Diff: http://git-wip-us.apache.org/repos/asf/zeppelin/diff/88184636
Branch: refs/heads/master
Commit: 881846364b08ec2086cd212fe500ee1518e1fd59
Parents: 1add74b
Author: Jeff Zhang <zj...@apache.org>
Authored: Wed Apr 4 09:51:33 2018 +0800
Committer: Jongyoul Lee <jo...@apache.org>
Committed: Thu Apr 5 17:09:23 2018 +0900
----------------------------------------------------------------------
.../java/org/apache/zeppelin/interpreter/InterpreterSetting.java | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/zeppelin/blob/88184636/zeppelin-zengine/src/main/java/org/apache/zeppelin/interpreter/InterpreterSetting.java
----------------------------------------------------------------------
diff --git a/zeppelin-zengine/src/main/java/org/apache/zeppelin/interpreter/InterpreterSetting.java b/zeppelin-zengine/src/main/java/org/apache/zeppelin/interpreter/InterpreterSetting.java
index ed8def0..21de851 100644
--- a/zeppelin-zengine/src/main/java/org/apache/zeppelin/interpreter/InterpreterSetting.java
+++ b/zeppelin-zengine/src/main/java/org/apache/zeppelin/interpreter/InterpreterSetting.java
@@ -495,7 +495,7 @@ public class InterpreterSetting {
StringMap<String> map = (StringMap) properties;
Properties newProperties = new Properties();
for (String key : map.keySet()) {
- newProperties.put(StringUtils.trim(key), StringUtils.trim(map.get(key)));
+ newProperties.put(key, map.get(key));
}
this.properties = newProperties;
} else {
@@ -520,7 +520,7 @@ public class InterpreterSetting {
Map<String, InterpreterProperty> iProperties = (Map<String, InterpreterProperty>) properties;
for (Map.Entry<String, InterpreterProperty> entry : iProperties.entrySet()) {
if (entry.getValue().getValue() != null) {
- jProperties.setProperty(entry.getKey(), entry.getValue().getValue().toString());
+ jProperties.setProperty(entry.getKey().trim(), entry.getValue().getValue().toString().trim());
}
}