Created 07-13-2017 04:22 PM
Dear All,
I am new not Zeppelin notebook, I have come across some strange behavior.
1. The variables and functions declared one notebook, can be accessible from another notebook.
a. Why this feature is available ?
b. How avoid this feature if possible ?
c.How to clear the variables and the functions from the memory ?
Created on 07-13-2017 04:56 PM - edited 08-18-2019 02:10 AM
@shivanand khobanna Are you defining those variables with %spark interpreter ? In that case, the default mode of %spark interpreter is 'Globally Shared'
In Shared mode, single JVM process and single Interpreter Group serves all Notes. Hence you might see variables defined in one note available to all users and all notebooks. So the behavior you are seeing is by design. You can change your interpreter modes through interpreters page. But better use 'livy' interpreter which uses 'Per user scoped' mode by default on HDP installed zeppelin. That means that you will see different YARN APPs for each user who is trying to use %livy interpreter and hence different spark context for each user which disables the sharing of namespace variables defined by one user from the other user.
Please checkout this article for more info on various zeppelin interpreter modes and what each of the modes means:
https://medium.com/@leemoonsoo/apache-zeppelin-interpreter-mode-explained-bae0525d0555
Created on 07-13-2017 04:56 PM - edited 08-18-2019 02:10 AM
@shivanand khobanna Are you defining those variables with %spark interpreter ? In that case, the default mode of %spark interpreter is 'Globally Shared'
In Shared mode, single JVM process and single Interpreter Group serves all Notes. Hence you might see variables defined in one note available to all users and all notebooks. So the behavior you are seeing is by design. You can change your interpreter modes through interpreters page. But better use 'livy' interpreter which uses 'Per user scoped' mode by default on HDP installed zeppelin. That means that you will see different YARN APPs for each user who is trying to use %livy interpreter and hence different spark context for each user which disables the sharing of namespace variables defined by one user from the other user.
Please checkout this article for more info on various zeppelin interpreter modes and what each of the modes means:
https://medium.com/@leemoonsoo/apache-zeppelin-interpreter-mode-explained-bae0525d0555