Martin
11/20/2024, 4:23 PM// This creates a new classloader, is it GC'd at the end of the work if nothing else keeps a reference?
val workQueue = getWorkerExecutor().classLoaderIsolation { workerSpec ->
workerSpec.classpath.from(classpath)
}
Martin
11/20/2024, 4:25 PMAnze Sodja
11/20/2024, 4:47 PMMartin
11/20/2024, 4:52 PMMartin
11/20/2024, 5:22 PMAnze Sodja
11/20/2024, 5:54 PMMartin
11/20/2024, 10:34 PMAnze Sodja
11/21/2024, 8:56 AMClassloader reuse for classloader isolation has always been something that we planned to implement, but was de-prioritized before we got around to it. The caching of the generated work classes was added later and it seems it was never clear the effect this had on these classloader isolated work items. This creates the worst of both worlds (i.e. caching stuff that is never reused).So basically there is some caching involved to reuse classloaders, but it's not effective and have negative consequences.
Martin
11/21/2024, 9:04 AMMartin
12/12/2024, 12:47 PM