The JVM prints a warning message if there is an unsupported option at CDS dump time.
bin/java -Xshare:dump --upgrade-module-path .
"Java HotSpot(TM) 64-Bit Server VM warning: the --upgrade-module-path option is ignored when dumping the shared archive"
bin/java -Xshare:dump --patch-module=java.naming=hello.jar
"Java HotSpot(TM) 64-Bit Server VM warning: the --patch-module option is ignored when dumping the shared archive"
The warning message should not be printed by default. It should only be printed with -XX:+PrintSharedSpaces.
bin/java -Xshare:dump --upgrade-module-path .
"Java HotSpot(TM) 64-Bit Server VM warning: the --upgrade-module-path option is ignored when dumping the shared archive"
bin/java -Xshare:dump --patch-module=java.naming=hello.jar
"Java HotSpot(TM) 64-Bit Server VM warning: the --patch-module option is ignored when dumping the shared archive"
The warning message should not be printed by default. It should only be printed with -XX:+PrintSharedSpaces.