@Test public void testGlobalImpersonationPropertyTRUE() { System.setProperty(PROPERTY_KEY_USER_IMPERSONATION, "TRUE"); assertTrue(secureLogin.isUserImpersonationEnabled(configuration)); }
public boolean isUserImpersonationEnabled(Configuration configuration) { String valueFromUserImpersonationOnServer = configuration.get(SecureLogin.CONFIG_KEY_SERVICE_USER_IMPERSONATION, System.getProperty(PROPERTY_KEY_USER_IMPERSONATION, "false")); return StringUtils.equalsIgnoreCase(valueFromUserImpersonationOnServer, "true"); }
SecureLogin { public boolean isUserImpersonationEnabled(Configuration configuration) { String valueFromUserImpersonationOnServer = configuration.get(SecureLogin.CONFIG_KEY_SERVICE_USER_IMPERSONATION, System.getProperty(PROPERTY_KEY_USER_IMPERSONATION, "false")); return StringUtils.equalsIgnoreCase(valueFromUserImpersonationOnServer, "true"); } }
SecureLogin { public boolean isUserImpersonationEnabled(Configuration configuration) { String valueFromUserImpersonationOnServer = configuration.get(SecureLogin.CONFIG_KEY_SERVICE_USER_IMPERSONATION, System.getProperty(PROPERTY_KEY_USER_IMPERSONATION, "false")); return StringUtils.equalsIgnoreCase(valueFromUserImpersonationOnServer, "true"); } private  SecureLogin(); }
SecureLogin { public boolean isUserImpersonationEnabled(Configuration configuration) { String valueFromUserImpersonationOnServer = configuration.get(SecureLogin.CONFIG_KEY_SERVICE_USER_IMPERSONATION, System.getProperty(PROPERTY_KEY_USER_IMPERSONATION, "false")); return StringUtils.equalsIgnoreCase(valueFromUserImpersonationOnServer, "true"); } private  SecureLogin(); static SecureLogin getInstance(); UserGroupInformation getLoginUser(RequestContext context, Configuration configuration); UserGroupInformation getLoginUser(String serverName, String configDirectory, Configuration configuration); boolean isUserImpersonationEnabled(Configuration configuration); }
SecureLogin { public boolean isUserImpersonationEnabled(Configuration configuration) { String valueFromUserImpersonationOnServer = configuration.get(SecureLogin.CONFIG_KEY_SERVICE_USER_IMPERSONATION, System.getProperty(PROPERTY_KEY_USER_IMPERSONATION, "false")); return StringUtils.equalsIgnoreCase(valueFromUserImpersonationOnServer, "true"); } private  SecureLogin(); static SecureLogin getInstance(); UserGroupInformation getLoginUser(RequestContext context, Configuration configuration); UserGroupInformation getLoginUser(String serverName, String configDirectory, Configuration configuration); boolean isUserImpersonationEnabled(Configuration configuration); static final String CONFIG_KEY_SERVICE_PRINCIPAL; static final String CONFIG_KEY_SERVICE_KEYTAB; static final String CONFIG_KEY_SERVICE_USER_IMPERSONATION; static final String CONFIG_KEY_SERVICE_USER_NAME; }