FANNG1 commented on code in PR #7827:
URL: https://github.com/apache/gravitino/pull/7827#discussion_r2239966210


##########
iceberg/iceberg-rest-server/src/test/java/org/apache/gravitino/iceberg/integration/test/IcebergRestKerberosHiveCatalogIT.java:
##########
@@ -157,4 +158,20 @@ private static boolean isEmbedded() {
 
     return Objects.equals(mode, ITUtils.EMBEDDED_TEST_MODE);
   }
+
+  private static void refreshKerberosConfig() {
+    Class<?> classRef;
+    try {
+      if (System.getProperty("java.vendor").contains("IBM")) {
+        classRef = Class.forName("com.ibm.security.krb5.internal.Config");
+      } else {
+        classRef = Class.forName("sun.security.krb5.Config");
+      }
+
+      Method refershMethod = classRef.getMethod("refresh");
+      refershMethod.invoke(null);
+    } catch (Exception e) {
+      throw new RuntimeException(e);
+    }
+  }

Review Comment:
   seems caused by upgrading the target compatibility from 8 to 17, the 
`sun.security.krb5` is not visible anymore.
   ```
   error: package sun.security.krb5 is not visible
         sun.security.krb5.Config.refresh();
                     ^
     (package sun.security.krb5 is declared in module java.security.jgss, which 
does not export it to the unnamed module)
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to