-
Notifications
You must be signed in to change notification settings - Fork 28
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Child only resource discovery #145
Conversation
Thank you for opening this pull request! 🙌 |
@@ -42,6 +45,9 @@ class ChildFirstClassLoader extends URLClassLoader { | |||
private static final String[] PARENT_FIRST_PACKAGE_PREFIXES = | |||
new String[] {"org.flyte.api.v1.", "org.flyte.jflyte.api."}; | |||
|
|||
private static final Set<String> CHILD_ONLY_RESOURCES = |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This project is still targeting Java 8, so no factory method from Set
to use.
8bbc509
to
c044752
Compare
01e38ef
to
66bafbd
Compare
Signed-off-by: Hongxin Liang <honnix@users.noreply.github.com>
66bafbd
to
bfdf6f6
Compare
I don't have permission to merge. Maybe I should be added to some team? |
Congrats on merging your first pull request! 🎉 |
TL;DR
Configure child only resource discovery to avoid discovering certain resources across class loaders.
Type
Are all requirements met?
Complete description
For certain resources such as
org/slf4j/impl/StaticLoggerBinder.class
, it does not make sense to discovery a parent one because it will almost certain cause classloading problem when mixing parent class and child class.Tracking Issue
Closes flyteorg/flyte#3051
Follow-up issue
NA