From 0771e1f19c5735e92aff2c226c74566f7ce31727 Mon Sep 17 00:00:00 2001 From: Will Mooreston Date: Tue, 25 Aug 2026 15:24:54 -0700 Subject: [PATCH] Issue 1528: enable native access to silence JNA warning on Java 25+ MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Appends --enable-native-access=ALL-UNNAMED to JAVA_REFLECTION_JAR_OPS in the embedded-Tomcat systemd unit. JNA (pulled in transitively by docker-java for the docker module) calls System.load, which JEP 472 now flags as a restricted method — this tells the JVM native access is expected. --- install-labkey.bash | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/install-labkey.bash b/install-labkey.bash index f83d3f6..c4c7c7d 100755 --- a/install-labkey.bash +++ b/install-labkey.bash @@ -1085,7 +1085,7 @@ function step_tomcat_service_embedded() { LABKEY_JAR_OPS="-Dlabkey.home=${LABKEY_INSTALL_HOME} -Dlabkey.log.home=${LABKEY_INSTALL_HOME}/logs -Dlabkey.externalModulesDir=${LABKEY_INSTALL_HOME}/externalModules -Djava.io.tmpdir=${TOMCAT_TMP_DIR}" JAVA_FLAGS_JAR_OPS="-Dorg.apache.catalina.startup.EXIT_ON_INIT_FAILURE=true -DsynchronousStartup=true -DterminateOnStartupFailure=true" JAVA_LOG_JAR_OPS="-XX:ErrorFile=${LABKEY_INSTALL_HOME}/logs/error_%p.log -Dlog4j.configurationFile=log4j2.xml" - JAVA_REFLECTION_JAR_OPS="--add-opens=java.base/java.lang=ALL-UNNAMED --add-opens=java.base/java.io=ALL-UNNAMED --add-opens=java.base/java.nio=ALL-UNNAMED --add-opens=java.base/java.util=ALL-UNNAMED --add-opens=java.base/java.util.concurrent=ALL-UNNAMED --add-opens=java.rmi/sun.rmi.transport=ALL-UNNAMED" + JAVA_REFLECTION_JAR_OPS="--add-opens=java.base/java.lang=ALL-UNNAMED --add-opens=java.base/java.io=ALL-UNNAMED --add-opens=java.base/java.nio=ALL-UNNAMED --add-opens=java.base/java.util=ALL-UNNAMED --add-opens=java.base/java.util.concurrent=ALL-UNNAMED --add-opens=java.rmi/sun.rmi.transport=ALL-UNNAMED --enable-native-access=ALL-UNNAMED" JAVA_TIMEZONE="-Duser.timezone=${TOMCAT_TIMEZONE}" LOCKFILE="$LABKEY_INSTALL_HOME/labkeyUpgradeLockFile"