chrisdchristo / capsule-maven-plugin

Capsule Maven Plugin
MIT License
58 stars 13 forks source link

Warning with JDK11 #59

Open vertex-github opened 6 years ago

vertex-github commented 6 years ago
WARNING: An illegal reflective access operation has occurred
WARNING: Illegal reflective access by Capsule (file:/Users/vertex/WorkingCopies/jAPlus/AMon/target/AMon-1.0-SNAPSHOT-fat.jar) to field com.sun.jmx.mbeanserver.JmxMBeanServer.mbsInterceptor
WARNING: Please consider reporting this to the maintainers of Capsule
WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
WARNING: All illegal access operations will be denied in a future release
tuxji commented 3 years ago

Until someone fixes the capsule code, here is a workaround which will suppress the warnings:

java --add-opens java.management/com.sun.jmx.mbeanserver=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED -jar <your-app-capsule.jar>