hvanhovell commented on code in PR #42069:
URL: https://github.com/apache/spark/pull/42069#discussion_r1278217400
##########
core/src/main/scala/org/apache/spark/executor/Executor.scala:
##########
@@ -1101,11 +1147,21 @@ private[spark] class Executor(
// Add it to our class loader
val url = new File(root, localName).toURI.toURL
if (!state.urlClassLoader.getURLs().contains(url)) {
- logInfo(s"Adding $url to class loader")
+ logInfo(s"Adding $url to class loader ${state.sessionUUID}")
state.urlClassLoader.addURL(url)
+ if (!isDefaultState(state.sessionUUID)) {
+ updated = true
+ }
}
}
}
+ if (updated) {
+ // When a new url is added for non-default class loader, recreate the
class loader
+ // to ensure all classes are updated.
+ state.urlClassLoader = createClassLoader(state.urlClassLoader.getURLs,
useStub = true)
Review Comment:
nvm I get it.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]