-
Notifications
You must be signed in to change notification settings - Fork 17
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
Add explicit module-info class file, to prevent resolving all automatic modules #17
Comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Is your feature request related to a problem? Please describe.
At current moment jakarta-inject library have Automatic-Module-Name attribute, if we using boot classloader it's ok.
But when multi-classloader env, resolving automatic modules have problem. Problem in this jdk code https://github.com/openjdk/jdk/blob/master/src/java.base/share/classes/java/lang/module/Resolver.java#L160
For example:
Describe the solution you'd like
Add module-info class file to jar file. It can be placed in jar root, or in META-INF/versions/9/, old jvms skip this file anyway.
There many ways how generate it. Check gson library or log4j2.
Also up release to 9 target.
I use own maven-plugin which generate module-info, and place it to target directory (https://github.com/consulo/java9-maven-plugin)
Describe alternatives you've considered
Leave as is Automatic-Module-Name
Thanks
The text was updated successfully, but these errors were encountered: