-
- Downloads
[SPARK-18646][REPL] Set parent classloader as null for ExecutorClassLoader
## What changes were proposed in this pull request? `ClassLoader` will preferentially load class from `parent`. Only when `parent` is null or the load failed, that it will call the overridden `findClass` function. To avoid the potential issue caused by loading class using inappropriate class loader, we should set the `parent` of `ClassLoader` to null, so that we can fully control which class loader is used. This is take over of #17074, the primary author of this PR is taroplus . Should close #17074 after this PR get merged. ## How was this patch tested? Add test case in `ExecutorClassLoaderSuite`. Author: Kohki Nishio <taroplus@me.com> Author: Xingbo Jiang <xingbo.jiang@databricks.com> Closes #18614 from jiangxb1987/executor_classloader.
Showing
- repl/src/main/scala/org/apache/spark/repl/ExecutorClassLoader.scala 11 additions, 6 deletions...ain/scala/org/apache/spark/repl/ExecutorClassLoader.scala
- repl/src/test/scala/org/apache/spark/repl/ExecutorClassLoaderSuite.scala 46 additions, 0 deletions...cala/org/apache/spark/repl/ExecutorClassLoaderSuite.scala
Loading
Please register or sign in to comment