dengzhhu653 commented on code in PR #6024: URL: https://github.com/apache/hive/pull/6024#discussion_r2286741804
########## shims/common/src/main/java/org/apache/hadoop/hive/shims/Utils.java: ########## @@ -55,6 +56,21 @@ public class Utils { public static final String DISTCP_OPTIONS_PREFIX = "distcp.options."; + + private static Method getKeytab = null; + static { + Class<?> clz = UserGroupInformation.class; + + try { + getKeytab = clz.getDeclaredMethod("getKeytab"); + getKeytab.setAccessible(true); + } catch(NoSuchMethodException nme) { + LOG.warn("Cannot find private method \"getKeytab\" in class:" + Review Comment: Just in case, this is called from static block, we need to catch this `NoSuchMethodException` explicitly. -- 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: gitbox-unsubscr...@hive.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: gitbox-unsubscr...@hive.apache.org For additional commands, e-mail: gitbox-h...@hive.apache.org