node-java-bridge icon indicating copy to clipboard operation
node-java-bridge copied to clipboard

Convert to named module

Open sosoba opened this issue 4 months ago • 0 comments

Is your feature request related to a problem? Please describe. Java 25 (LTS now) reports a crusade against unnamed modules:

WARNING: A restricted method in java.lang.Runtime has been called
WARNING: java.lang.Runtime::load has been called by io.github.markusjx.bridge.NativeLibrary in an unnamed module (file:/C:/workspace/test/node_modules/java-bridge/dist/JavaBridge.jar)
WARNING: Use --enable-native-access=ALL-UNNAMED to avoid a warning for callers in this module
WARNING: Restricted methods will be blocked in a future release unless native access is enabled

Describe the solution you'd like Try to convert JavaBridge.jar into named module.

Describe alternatives you've considered

javaBridge.ensureJvm({opts: [
  '--enable-native-access=ALL-UNNAMED', // works until next Java generation
]})

sosoba avatar Sep 22 '25 09:09 sosoba