Fix Version/s: 14
Compatibility Risk Description:The CSR is for adding documentation of existing functionality. It does not change behavior.
Add text to Chapter 5 of the JNI Spec that clarifies how to pass long-form options, such as --add-exports, to JNI_CreateJavaVM().
The JNI Spec needs to tell users how to correctly pass long-form options to the JVM when using the JNI_CreateJavaVM() API.
Add the needed text to the JNI_CreateJavaVM() description in chapter 5 of the JNI Spec:
The detailed changes are to add the following paragraph to the description of JNI_CreateJavaVM in chapter 5 of the JNI Spec. The paragraph would be placed before the example that is currently in the Spec.
The proposed new paragraph is:
Also, the VM accepts relevant long-form options provided that the option arguments are separated from their option names by '=' and there is no intervening white space. For example, to export java.management/sun.management to ALL-UNNAMED, the option string "--add-exports=java.management/sun.management=ALL-UNNAMED" should be used.
This paragraph will be deleted:
The module related options,
--upgrade-module-path must be passed as option strings using their "option=value" format instead of their "option value" format. (Note the required
= between "option" and "value".) For example, to export
ALL-UNNAMED pass option string
The JDK-13 description of JNI_CreateJavaVM in the JNI Spec can be found here: https://docs.oracle.com/en/java/javase/13/docs/specs/jni/invocation.html#jni_createjavavm