Repository: zeppelin Updated Branches: refs/heads/master bf923dc13 -> bfb04af39
[ZEPPELIN-3241] fix NPE when restarting Interpreter ### What is this PR for? We often (but not always) face an NPE when restarting Spark interpreter. Our Spark interpreter run in scoped mode per note. The restart then is not possible, only restart of whole zeppelin daemon helps out. This PR fixes this NPE. ### What type of PR is it? Bug Fix ### Todos ### What is the Jira issue? [https://issues.apache.org/jira/browse/ZEPPELIN-3241](https://issues.apache.org/jira/browse/ZEPPELIN-3241) ### How should this be tested? - manual ### 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: Andreas Weise <a.we...@avm.de> Closes #2806 from weand/ZEPPELIN-3241 and squashes the following commits: 85c0448 [Andreas Weise] ZEPPELIN-3241: NPE when restarting Interpreter Project: http://git-wip-us.apache.org/repos/asf/zeppelin/repo Commit: http://git-wip-us.apache.org/repos/asf/zeppelin/commit/bfb04af3 Tree: http://git-wip-us.apache.org/repos/asf/zeppelin/tree/bfb04af3 Diff: http://git-wip-us.apache.org/repos/asf/zeppelin/diff/bfb04af3 Branch: refs/heads/master Commit: bfb04af395b7815c8765e709639e4b86bdd64884 Parents: bf923dc Author: Andreas Weise <a.we...@avm.de> Authored: Fri Feb 16 22:45:59 2018 +0100 Committer: Jeff Zhang <zjf...@apache.org> Committed: Sun Feb 18 16:36:30 2018 +0800 ---------------------------------------------------------------------- .../src/main/java/org/apache/zeppelin/notebook/Paragraph.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/zeppelin/blob/bfb04af3/zeppelin-zengine/src/main/java/org/apache/zeppelin/notebook/Paragraph.java ---------------------------------------------------------------------- diff --git a/zeppelin-zengine/src/main/java/org/apache/zeppelin/notebook/Paragraph.java b/zeppelin-zengine/src/main/java/org/apache/zeppelin/notebook/Paragraph.java index 20f9ff8..76c48c8 100644 --- a/zeppelin-zengine/src/main/java/org/apache/zeppelin/notebook/Paragraph.java +++ b/zeppelin-zengine/src/main/java/org/apache/zeppelin/notebook/Paragraph.java @@ -728,7 +728,7 @@ public class Paragraph extends Job implements Cloneable, JsonSerializable { * @param settingId */ public void clearRuntimeInfo(String settingId) { - if (settingId != null) { + if (settingId != null && runtimeInfos != null) { Set<String> keys = runtimeInfos.keySet(); if (keys.size() > 0) { List<String> infosToRemove = new ArrayList<>();