Skip to content

Fix to class loader to ensure tasks receive the appropriate classpath…#1508

Closed
revprez wants to merge 1 commit intoapache:release-0.10from
OCForks:spring-classloading-fix-0.10
Closed

Fix to class loader to ensure tasks receive the appropriate classpath…#1508
revprez wants to merge 1 commit intoapache:release-0.10from
OCForks:spring-classloading-fix-0.10

Conversation

@revprez
Copy link
Copy Markdown
Contributor

@revprez revprez commented Jan 14, 2016

ClassNotFoundException thrown by task runners after Maven emits a fat-jar instrumented with Spring Boot.

Here's a gist, and here's the report, discussion and solution. H/t to Stephan Ewen; I just did what he told me to do.

StephanEwen pushed a commit to StephanEwen/flink that referenced this pull request Jan 14, 2016
…der from Flink core classes

Originally, the user code classloader delegates to the system classloader as parent.
That works in Flink standalone settings, but not when the Flink core classes themselves
 are not loaded with the system classloader (certain embedded setups).

This patch uses as parent the classloader that was used to load the Flink core classes, specificly
"org.apache.flink.runtime.execution.librarycache.BlobLibraryCacheManager.FlinkUserCodeClassLoader.class.getClassLoader()".

This closes apache#1506
This closes apache#1507
This closes apache#1508
StephanEwen pushed a commit to StephanEwen/flink that referenced this pull request Jan 14, 2016
…der from Flink core classes

Originally, the user code classloader delegates to the system classloader as parent.
That works in Flink standalone settings, but not when the Flink core classes themselves
 are not loaded with the system classloader (certain embedded setups).

This patch uses as parent the classloader that was used to load the Flink core classes, specificly
"org.apache.flink.runtime.execution.librarycache.BlobLibraryCacheManager.FlinkUserCodeClassLoader.class.getClassLoader()".

This closes apache#1506
This closes apache#1507
This closes apache#1508
@asfgit asfgit closed this in 0ae46b5 Jan 15, 2016
ChengXiangLi pushed a commit to ChengXiangLi/flink that referenced this pull request Jan 25, 2016
…der from Flink core classes

Originally, the user code classloader delegates to the system classloader as parent.
That works in Flink standalone settings, but not when the Flink core classes themselves
 are not loaded with the system classloader (certain embedded setups).

This patch uses as parent the classloader that was used to load the Flink core classes, specificly
"org.apache.flink.runtime.execution.librarycache.BlobLibraryCacheManager.FlinkUserCodeClassLoader.class.getClassLoader()".

This closes apache#1506
This closes apache#1507
This closes apache#1508
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant