zeppelin-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From m...@apache.org
Subject [43/50] incubator-zeppelin git commit: Error message for unsupported pyspark version
Date Fri, 20 Mar 2015 18:02:05 GMT
Error message for unsupported pyspark version


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

Branch: refs/heads/master
Commit: 1c2dfb8c2d158e2ff991ac7ba05164e9b092529e
Parents: 03319d7
Author: Lee moon soo <leemoonsoo@gmail.com>
Authored: Mon Mar 16 16:37:14 2015 +0900
Committer: Lee moon soo <leemoonsoo@gmail.com>
Committed: Mon Mar 16 16:37:14 2015 +0900

----------------------------------------------------------------------
 .../main/java/com/nflabs/zeppelin/spark/PySparkInterpreter.java  | 4 ++++
 1 file changed, 4 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-zeppelin/blob/1c2dfb8c/spark/src/main/java/com/nflabs/zeppelin/spark/PySparkInterpreter.java
----------------------------------------------------------------------
diff --git a/spark/src/main/java/com/nflabs/zeppelin/spark/PySparkInterpreter.java b/spark/src/main/java/com/nflabs/zeppelin/spark/PySparkInterpreter.java
index 5e277cd..5f5386e 100644
--- a/spark/src/main/java/com/nflabs/zeppelin/spark/PySparkInterpreter.java
+++ b/spark/src/main/java/com/nflabs/zeppelin/spark/PySparkInterpreter.java
@@ -242,6 +242,10 @@ public class PySparkInterpreter extends Interpreter implements ExecuteResultHand
     }
 
     SparkInterpreter sparkInterpreter = getSparkInterpreter();
+    if (!sparkInterpreter.getSparkContext().version().startsWith("1.2")) {
+      return new InterpreterResult(Code.ERROR, "pyspark "
+          + sparkInterpreter.getSparkContext().version() + " is not supported");
+    }
     String jobGroup = sparkInterpreter.getJobGroup(context);
     ZeppelinContext z = sparkInterpreter.getZeppelinContext();
     z.setInterpreterContext(context);


Mime
View raw message