I have three applications I deploy with Java Web Start to clients. All three of these applications use JAXB. Under Java 1.9 to get the jaxb module loaded you have to use:
--add-modules java.xml.bind
Java Web Start let's you pass VM arguments to applications with the java-vm-args attribute of the java/j2se tag. However, only the arguments listed in the documentation are supported and --add-modules
is not in that list.
So the question is how do you pass "--add-modules java.xml.bind"
to the 1.9 VM when running code via Java Web Start that uses JAXB?
Here is what I tried and my testing shows that --add-modules is indeed not supported by the java-vm-arg attribute:
<resources>
<property name="jnlp.packEnabled" value="true"/>
<java version="9" java-vm-args="--add-modules java.xml.bind"/>
<java version="1.8+"/>
<jar href="redacted.jar"/>
</resources>