JDK-8210087 [1] is an issue with the launcher generated for jconsole. The launcher needs to be compiled with --add-modules ALL-DEFAULT so that plugins compiled (and run) in an unnamed module can make use of exported APIs in modules that aren't resolved by jdk.jconsole. The change is trivial:

diff -r cdef4df6b0e7 make/launcher/Launcher-jdk.jconsole.gmk
--- a/make/launcher/Launcher-jdk.jconsole.gmk    Fri Aug 31 10:22:04 2018 -0400 +++ b/make/launcher/Launcher-jdk.jconsole.gmk    Mon Sep 03 07:56:56 2018 +0100
@@ -28,6 +28,7 @@
 $(eval $(call SetupBuildLauncher, jconsole, \
     MAIN_CLASS := sun.tools.jconsole.JConsole, \
     JAVA_ARGS := --add-opens java.base/java.io=jdk.jconsole \
+                 --add-modules ALL-DEFAULT \
          -Djconsole.showOutputViewer, \
     CFLAGS_windows := -DJAVAW, \
     LIBS_windows := user32.lib, \

jconsole is headful so I'm not planning to include a test at this time.

-Alan

[1] https://bugs.openjdk.java.net/browse/JDK-8210087

Reply via email to