-
Notifications
You must be signed in to change notification settings - Fork 96
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
module-info.java does not require java.xml directly #490
Comments
Hi Tom, |
sure - I'll take a look tomorrow and update the PR |
Great! Thank you for quick response and sorry for unexcusable delay from my side. |
As I maintain multiple OSS-Projects myself beside the company duties I'm assigned on you don't have to excuse for not directly following up. |
I applied the java.sql strategy and made the java.xml dependency static |
I've tried to use yasson in a project where I also use jlink to build a custom JRE. Looking the at the runtime dependencies of yasson it only requires:
as the other requires are defined as static. Building an image and launch although leads to the following error
The problem is caused because
java.desktop
andjava.sql
transitively requirejava.xml
so even linking injavax.xml
does not help because the yasson module is not going to find the classes injava.xml
unless the static module is there.My current fix is to link in
java.desktop
- I have no idea whyjava.sql
does not work - but ideally I can get rid of those extra bits.I tested with a modified
module-info.java
that adding arequires java.xml
fixes the problem.One could naturally argue now that
java.xml
should be required static and one would handle the CNF gracefully inDefaultSerializers
because if this (de)serializer is used the user anyways has to have him/her self a runtime dependency onjava.xml
.I'll provide a PR and this can be discussed there.
The text was updated successfully, but these errors were encountered: