You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by ps...@apache.org on 2024/01/09 17:31:45 UTC

(hbase) branch branch-2.6 updated: HBASE-28261 Sync jvm11 module flags from hbase-surefire.jdk11.flags to bin/hbase (#5610)

This is an automated email from the ASF dual-hosted git repository.

psomogyi pushed a commit to branch branch-2.6
in repository https://gitbox.apache.org/repos/asf/hbase.git


The following commit(s) were added to refs/heads/branch-2.6 by this push:
     new 9f43b732807 HBASE-28261 Sync jvm11 module flags from hbase-surefire.jdk11.flags to bin/hbase (#5610)
9f43b732807 is described below

commit 9f43b732807449bd3e8ec817360ac0837336dd31
Author: Istvan Toth <st...@apache.org>
AuthorDate: Tue Jan 9 16:50:29 2024 +0100

    HBASE-28261 Sync jvm11 module flags from hbase-surefire.jdk11.flags to bin/hbase (#5610)
    
    Signed-off-by: Nihal Jain <ni...@apache.org>
    Signed-off-by: Peter Somogyi <ps...@apache.org>
    (cherry picked from commit 0916c72929e238735e3dc3ec09dbf935e8d6ad69)
---
 bin/hbase | 3 ++-
 pom.xml   | 5 +++++
 2 files changed, 7 insertions(+), 1 deletion(-)

diff --git a/bin/hbase b/bin/hbase
index 73e582fa3ad..9f96f24fe9d 100755
--- a/bin/hbase
+++ b/bin/hbase
@@ -496,7 +496,8 @@ add_jdk11_deps_to_classpath() {
 }
 
 add_jdk11_jvm_flags() {
-  HBASE_OPTS="$HBASE_OPTS -Dorg.apache.hbase.thirdparty.io.netty.tryReflectionSetAccessible=true --add-modules jdk.unsupported --add-opens java.base/java.io=ALL-UNNAMED --add-opens java.base/java.nio=ALL-UNNAMED --add-opens java.base/sun.nio.ch=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/jdk.internal.ref=ALL-UNNAMED --add-opens java.base/java.lang.reflect=ALL-UNNAMED --add-exports java.base/jdk.internal.misc=ALL-UNNAMED --add-exports java.security.jgss/s [...]
+  # Keep in sync with hbase-surefire.jdk11.flags in the root pom.xml
+  HBASE_OPTS="$HBASE_OPTS -Dorg.apache.hbase.thirdparty.io.netty.tryReflectionSetAccessible=true --add-modules jdk.unsupported --add-opens java.base/java.io=ALL-UNNAMED --add-opens java.base/java.nio=ALL-UNNAMED --add-opens java.base/sun.nio.ch=ALL-UNNAMED --add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/jdk.internal.ref=ALL-UNNAMED --add-opens java.base/java.lang.reflect=ALL-UNNAMED --add-opens java.base/java.util=ALL-UNNAMED --add-opens java.base/java.util.concurrent=A [...]
 }
 
 add_opentelemetry_agent() {
diff --git a/pom.xml b/pom.xml
index dbe2d05849e..f872d6af9eb 100644
--- a/pom.xml
+++ b/pom.xml
@@ -720,8 +720,11 @@
       "-Djava.library.path=${hadoop.library.path};${java.library.path}"
       -Dorg.apache.hbase.thirdparty.io.netty.leakDetection.level=advanced
       -Dio.opentelemetry.context.enableStrictContext=true</hbase-surefire.cygwin-argLine>
+    <!-- Keep these options in sync with add_jdk11_jvm_flags() in bin/hbase.
+    Currently, all of these options are known to be required by HBase, and not the test cases -->
     <hbase-surefire.jdk11.flags>-Dorg.apache.hbase.thirdparty.io.netty.tryReflectionSetAccessible=true
       --add-modules jdk.unsupported
+      --add-opens java.base/java.io=ALL-UNNAMED
       --add-opens java.base/java.nio=ALL-UNNAMED
       --add-opens java.base/sun.nio.ch=ALL-UNNAMED
       --add-opens java.base/java.lang=ALL-UNNAMED
@@ -733,6 +736,8 @@
       --add-exports java.security.jgss/sun.security.krb5=ALL-UNNAMED
       --add-exports java.base/sun.net.dns=ALL-UNNAMED
       --add-exports java.base/sun.net.util=ALL-UNNAMED</hbase-surefire.jdk11.flags>
+    <!-- java.base/jdk.internal.util.random=ALL-UNNAMED is required by the test code, so we do not
+    need this in bin/hbase -->
     <hbase-surefire.jdk17.flags>--add-opens java.base/jdk.internal.util.random=ALL-UNNAMED</hbase-surefire.jdk17.flags>
     <!-- Surefire argLine defaults to Linux, cygwin argLine is used in the os.windows profile -->
     <argLine>${hbase-surefire.argLine} @{jacocoArgLine}</argLine>