Java Code Examples for org.apache.hadoop.security.UserGroupInformation#isLoginTicketBased()
The following examples show how to use
org.apache.hadoop.security.UserGroupInformation#isLoginTicketBased() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: KafkaNotification.java From atlas with Apache License 2.0 | 5 votes |
@VisibleForTesting boolean isLoginTicketBased() { boolean ret = false; try { ret = UserGroupInformation.isLoginTicketBased(); } catch (Exception excp) { LOG.warn("Error in determining ticket-cache for KafkaClient-JAAS config", excp); } return ret; }
Example 2
Source File: AtlasHook.java From incubator-atlas with Apache License 2.0 | 5 votes |
private static boolean isLoginTicketBased() { boolean ret = false; try { ret = UserGroupInformation.isLoginTicketBased(); } catch (Exception excp) { LOG.warn("Error in determining ticket-cache for KafkaClient-JAAS config", excp); } return ret; }
Example 3
Source File: JDBCInterpreter.java From zeppelin with Apache License 2.0 | 5 votes |
@Override protected boolean runKerberosLogin() { try { if (UserGroupInformation.isLoginKeytabBased()) { UserGroupInformation.getLoginUser().reloginFromKeytab(); return true; } else if (UserGroupInformation.isLoginTicketBased()) { UserGroupInformation.getLoginUser().reloginFromTicketCache(); return true; } } catch (Exception e) { LOGGER.error("Unable to run kinit for zeppelin", e); } return false; }