Skip to content

Commit 199507a

Browse files
authored
[4.4.x] Add --add-opens java.base/sun.nio.ch=ALL-UNNAMED (#3144)
1 parent 99ec5dc commit 199507a

8 files changed

Lines changed: 10 additions & 3 deletions

File tree

‎assemblies/features/base/src/main/filtered-resources/resources/bin/karaf‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -310,6 +310,7 @@ run() {
310310
--add-opens java.base/java.net=ALL-UNNAMED \
311311
--add-opens java.base/java.lang=ALL-UNNAMED \
312312
--add-opens java.base/java.util=ALL-UNNAMED \
313+
--add-opens java.base/sun.nio.ch=ALL-UNNAMED \
313314
--add-opens java.naming/javax.naming.spi=ALL-UNNAMED \
314315
--add-opens java.rmi/sun.rmi.transport.tcp=ALL-UNNAMED \
315316
--add-exports=java.base/sun.net.www.protocol.file=ALL-UNNAMED \

‎assemblies/features/base/src/main/filtered-resources/resources/bin/karaf.bat‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -437,6 +437,7 @@ if "%KARAF_PROFILER%" == "" goto :RUN
437437
--add-opens java.base/java.net=ALL-UNNAMED ^
438438
--add-opens java.base/java.lang=ALL-UNNAMED ^
439439
--add-opens java.base/java.util=ALL-UNNAMED ^
440+
--add-opens java.base/sun.nio.ch=ALL-UNNAMED ^
440441
--add-opens java.naming/javax.naming.spi=ALL-UNNAMED ^
441442
--add-opens java.rmi/sun.rmi.transport.tcp=ALL-UNNAMED ^
442443
--add-exports=java.base/sun.net.www.protocol.file=ALL-UNNAMED ^

‎instance/src/main/java/org/apache/karaf/instance/core/internal/InstanceServiceImpl.java‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -571,6 +571,7 @@ private void doStart(InstanceState instance, String name, String javaOpts) throw
571571
" --add-opens java.base/java.net=ALL-UNNAMED" +
572572
" --add-opens java.base/java.lang=ALL-UNNAMED" +
573573
" --add-opens java.base/java.util=ALL-UNNAMED" +
574+
" --add-opens java.base/sun.nio.ch=ALL-UNNAMED" +
574575
" --add-opens java.naming/javax.naming.spi=ALL-UNNAMED" +
575576
" --add-opens java.rmi/sun.rmi.transport.tcp=ALL-UNNAMED" +
576577
" --add-exports=java.base/sun.net.www.protocol.file=ALL-UNNAMED" +

‎itests/common/src/main/java/org/apache/karaf/itests/KarafTestSupport.java‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -276,6 +276,8 @@ public Option[] config() {
276276
new VMOption("--add-opens"),
277277
new VMOption("java.base/java.util=ALL-UNNAMED"),
278278
new VMOption("--add-opens"),
279+
new VMOption("java.base/sun.nio.ch=ALL-UNNAMED"),
280+
new VMOption("--add-opens"),
279281
new VMOption("java.naming/javax.naming.spi=ALL-UNNAMED"),
280282
new VMOption("--add-opens"),
281283
new VMOption("java.rmi/sun.rmi.transport.tcp=ALL-UNNAMED"),

‎itests/test/src/test/java/org/apache/karaf/itests/mavenresolver/KarafMinimalMonitoredTestSupport.java‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -106,6 +106,8 @@ public Option[] baseConfig() throws Exception {
106106
new VMOption("--add-opens"),
107107
new VMOption("java.base/java.util=ALL-UNNAMED"),
108108
new VMOption("--add-opens"),
109+
new VMOption("java.base/sun.nio.ch=ALL-UNNAMED"),
110+
new VMOption("--add-opens"),
109111
new VMOption("java.naming/javax.naming.spi=ALL-UNNAMED"),
110112
new VMOption("--add-opens"),
111113
new VMOption("java.rmi/sun.rmi.transport.tcp=ALL-UNNAMED"),

‎wrapper/src/main/resources/org/apache/karaf/wrapper/internal/unix/karaf-wrapper-java11.conf‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ set.default.PATH_WITH_JAVA=%JAVA_HOME%%WRAPPER_FILE_SEPARATOR%bin%WRAPPER_PATH_S
3030
# Include JAVA_HOME/bin in the default PATH variable
3131
set.PATH=%PATH_WITH_JAVA%
3232

33-
set.JDK_JAVA_OPTIONS=--add-reads=java.xml=java.logging --add-exports=java.base/org.apache.karaf.specs.locator=java.xml,ALL-UNNAMED --patch-module java.base=%KARAF_HOME%/lib/endorsed/org.apache.karaf.specs.locator-%KARAF_VERSION%.jar --patch-module java.xml=%KARAF_HOME%/lib/endorsed/org.apache.karaf.specs.java.xml-%KARAF_VERSION%.jar --add-opens java.base/java.security=ALL-UNNAMED --add-opens java.base/java.net=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/java.util=ALL-UNNAMED --add-opens java.naming/javax.naming.spi=ALL-UNNAMED --add-opens java.rmi/sun.rmi.transport.tcp=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.file=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.ftp=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.http=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.https=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.jar=ALL-UNNAMED --add-exports=java.base/sun.net.www.content.text=ALL-UNNAMED --add-exports=jdk.xml.dom/org.w3c.dom.html=ALL-UNNAMED --add-exports=jdk.naming.rmi/com.sun.jndi.url.rmi=ALL-UNNAMED --add-exports=java.rmi/sun.rmi.registry=ALL-UNNAMED --add-exports=java.naming/com.sun.jndi.ldap=ALL-UNNAMED
33+
set.JDK_JAVA_OPTIONS=--add-reads=java.xml=java.logging --add-exports=java.base/org.apache.karaf.specs.locator=java.xml,ALL-UNNAMED --patch-module java.base=%KARAF_HOME%/lib/endorsed/org.apache.karaf.specs.locator-%KARAF_VERSION%.jar --patch-module java.xml=%KARAF_HOME%/lib/endorsed/org.apache.karaf.specs.java.xml-%KARAF_VERSION%.jar --add-opens java.base/java.security=ALL-UNNAMED --add-opens java.base/java.net=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/java.util=ALL-UNNAMED --add-opens java.base/sun.nio.ch=ALL-UNNAMED --add-opens java.naming/javax.naming.spi=ALL-UNNAMED --add-opens java.rmi/sun.rmi.transport.tcp=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.file=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.ftp=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.http=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.https=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.jar=ALL-UNNAMED --add-exports=java.base/sun.net.www.content.text=ALL-UNNAMED --add-exports=jdk.xml.dom/org.w3c.dom.html=ALL-UNNAMED --add-exports=jdk.naming.rmi/com.sun.jndi.url.rmi=ALL-UNNAMED --add-exports=java.rmi/sun.rmi.registry=ALL-UNNAMED --add-exports=java.naming/com.sun.jndi.ldap=ALL-UNNAMED
3434

3535
# Java Application
3636
wrapper.working.dir=%KARAF_BASE%

‎wrapper/src/main/resources/org/apache/karaf/wrapper/internal/windows/karaf-wrapper-java11.conf‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ set.default.PATH_WITH_JAVA=%JAVA_HOME%%WRAPPER_FILE_SEPARATOR%bin%WRAPPER_PATH_S
3030
# Include JAVA_HOME/bin in the default PATH variable
3131
set.PATH=%PATH_WITH_JAVA%
3232

33-
set.JDK_JAVA_OPTIONS=--add-reads=java.xml=java.logging --add-exports=java.base/org.apache.karaf.specs.locator=java.xml,ALL-UNNAMED --patch-module java.base=%KARAF_HOME%/lib/endorsed/org.apache.karaf.specs.locator-%KARAF_VERSION%.jar --patch-module java.xml=%KARAF_HOME%/lib/endorsed/org.apache.karaf.specs.java.xml-%KARAF_VERSION%.jar --add-opens java.base/java.security=ALL-UNNAMED --add-opens java.base/java.net=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/java.util=ALL-UNNAMED --add-opens java.naming/javax.naming.spi=ALL-UNNAMED --add-opens java.rmi/sun.rmi.transport.tcp=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.file=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.ftp=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.http=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.https=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.jar=ALL-UNNAMED --add-exports=java.base/sun.net.www.content.text=ALL-UNNAMED --add-exports=jdk.xml.dom/org.w3c.dom.html=ALL-UNNAMED --add-exports=jdk.naming.rmi/com.sun.jndi.url.rmi=ALL-UNNAMED --add-exports=java.rmi/sun.rmi.registry=ALL-UNNAMED --add-exports=java.naming/com.sun.jndi.ldap=ALL-UNNAMED
33+
set.JDK_JAVA_OPTIONS=--add-reads=java.xml=java.logging --add-exports=java.base/org.apache.karaf.specs.locator=java.xml,ALL-UNNAMED --patch-module java.base=%KARAF_HOME%/lib/endorsed/org.apache.karaf.specs.locator-%KARAF_VERSION%.jar --patch-module java.xml=%KARAF_HOME%/lib/endorsed/org.apache.karaf.specs.java.xml-%KARAF_VERSION%.jar --add-opens java.base/java.security=ALL-UNNAMED --add-opens java.base/java.net=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/java.util=ALL-UNNAMED --add-opens java.base/sun.nio.ch=ALL-UNNAMED --add-opens java.naming/javax.naming.spi=ALL-UNNAMED --add-opens java.rmi/sun.rmi.transport.tcp=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.file=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.ftp=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.http=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.https=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.jar=ALL-UNNAMED --add-exports=java.base/sun.net.www.content.text=ALL-UNNAMED --add-exports=jdk.xml.dom/org.w3c.dom.html=ALL-UNNAMED --add-exports=jdk.naming.rmi/com.sun.jndi.url.rmi=ALL-UNNAMED --add-exports=java.rmi/sun.rmi.registry=ALL-UNNAMED --add-exports=java.naming/com.sun.jndi.ldap=ALL-UNNAMED
3434

3535
# Java Application
3636
wrapper.working.dir=%KARAF_BASE%

‎wrapper/src/main/resources/org/apache/karaf/wrapper/internal/windows64/karaf-wrapper-java11.conf‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ set.default.PATH_WITH_JAVA=%JAVA_HOME%%WRAPPER_FILE_SEPARATOR%bin%WRAPPER_PATH_S
3030
# Include JAVA_HOME/bin in the default PATH variable
3131
set.PATH=%PATH_WITH_JAVA%
3232

33-
set.JDK_JAVA_OPTIONS=--add-reads=java.xml=java.logging --add-exports=java.base/org.apache.karaf.specs.locator=java.xml,ALL-UNNAMED --patch-module java.base=%KARAF_HOME%/lib/endorsed/org.apache.karaf.specs.locator-%KARAF_VERSION%.jar --patch-module java.xml=%KARAF_HOME%/lib/endorsed/org.apache.karaf.specs.java.xml-%KARAF_VERSION%.jar --add-opens java.base/java.security=ALL-UNNAMED --add-opens java.base/java.net=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/java.util=ALL-UNNAMED --add-opens java.naming/javax.naming.spi=ALL-UNNAMED --add-opens java.rmi/sun.rmi.transport.tcp=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.file=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.ftp=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.http=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.https=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.jar=ALL-UNNAMED --add-exports=java.base/sun.net.www.content.text=ALL-UNNAMED --add-exports=jdk.xml.dom/org.w3c.dom.html=ALL-UNNAMED --add-exports=jdk.naming.rmi/com.sun.jndi.url.rmi=ALL-UNNAMED --add-exports=java.rmi/sun.rmi.registry=ALL-UNNAMED --add-exports=java.naming/com.sun.jndi.ldap=ALL-UNNAMED
33+
set.JDK_JAVA_OPTIONS=--add-reads=java.xml=java.logging --add-exports=java.base/org.apache.karaf.specs.locator=java.xml,ALL-UNNAMED --patch-module java.base=%KARAF_HOME%/lib/endorsed/org.apache.karaf.specs.locator-%KARAF_VERSION%.jar --patch-module java.xml=%KARAF_HOME%/lib/endorsed/org.apache.karaf.specs.java.xml-%KARAF_VERSION%.jar --add-opens java.base/java.security=ALL-UNNAMED --add-opens java.base/java.net=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/java.util=ALL-UNNAMED --add-opens java.base/sun.nio.ch=ALL-UNNAMED --add-opens java.naming/javax.naming.spi=ALL-UNNAMED --add-opens java.rmi/sun.rmi.transport.tcp=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.file=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.ftp=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.http=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.https=ALL-UNNAMED --add-exports=java.base/sun.net.www.protocol.jar=ALL-UNNAMED --add-exports=java.base/sun.net.www.content.text=ALL-UNNAMED --add-exports=jdk.xml.dom/org.w3c.dom.html=ALL-UNNAMED --add-exports=jdk.naming.rmi/com.sun.jndi.url.rmi=ALL-UNNAMED --add-exports=java.rmi/sun.rmi.registry=ALL-UNNAMED --add-exports=java.naming/com.sun.jndi.ldap=ALL-UNNAMED
3434

3535
# Java Application
3636
wrapper.working.dir=%KARAF_BASE%

0 commit comments

Comments
 (0)