- Subscribe to RSS Feed
- Mark Question as New
- Mark Question as Read
- Float this Question for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
How to avoid sharing spark context between two Zeppelin notebooks?
- Labels:
-
Apache Spark
-
Apache Zeppelin
Created ‎12-11-2017 02:48 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
When you use Spark from a Zeppelin notebook, and at the end you isse a context stop,
sc.stop()
it affects the context of other running Zeppeling notebooks, making them fail because of no Spark active context. They seem to be sharing the same Spark context.
How can this be avoided?
Created on ‎12-12-2017 11:23 AM - edited ‎08-17-2019 06:24 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Sharing of interpreter processes is easily adjustable
Go to the interpreter setting page :
And scroll down to the spark interpreter :
By default interpreters are shared globaly : ie - all notes/users share the same interpreter instance (hence the same spark context)
Change the setting to either "per note" or "per user" depending on your use case :
- Per Note : ie - each note will instantiate a separate interpreter process
- Per User : ie - each user instantiates a seperate interpreter process (which is shared amongst the notes for which he/she has ownership)
Below an article written by one of the original developpers of zeppelin describing interpreter modes :
https://medium.com/@leemoonsoo/apache-zeppelin-interpreter-mode-explained-bae0525d0555
Zeppelin documentation:
https://zeppelin.apache.org/docs/latest/manual/interpreters.html#interpreter-binding-mode
Created on ‎12-12-2017 11:23 AM - edited ‎08-17-2019 06:24 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Sharing of interpreter processes is easily adjustable
Go to the interpreter setting page :
And scroll down to the spark interpreter :
By default interpreters are shared globaly : ie - all notes/users share the same interpreter instance (hence the same spark context)
Change the setting to either "per note" or "per user" depending on your use case :
- Per Note : ie - each note will instantiate a separate interpreter process
- Per User : ie - each user instantiates a seperate interpreter process (which is shared amongst the notes for which he/she has ownership)
Below an article written by one of the original developpers of zeppelin describing interpreter modes :
https://medium.com/@leemoonsoo/apache-zeppelin-interpreter-mode-explained-bae0525d0555
Zeppelin documentation:
https://zeppelin.apache.org/docs/latest/manual/interpreters.html#interpreter-binding-mode
