Created
March 16, 2017 01:35
-
-
Save SergeyAxenov/78ee661c75e934b19ec7dad69480179d to your computer and use it in GitHub Desktop.
Zeppelin 0.6.2 Use GUI params to save arbitrary paragraph data between the interpreter restarts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Shows how to persist paragraph data between spark interpreter restarts using Zeppelin GUI params storage | |
// Run it once, then restart interpreter and run again. Parameter "ax4_gui_param" shuld be restored | |
val ctx = z.getInterpreterContext | |
val param = ctx.getGui.getParams().get("ax4_gui_param") | |
if (param == null) { | |
s"Parameter is not persisted. Setting initial value" | |
ctx.getGui.getParams().put("ax4_gui_param","hello_gui_param") | |
} else { | |
s"Parameter is restored from Zeppelin GUI params collection: $param" | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment