@Test public void testGetBlackListedSuperUsers() { List<String> expectedBlackListedUsers = Arrays.asList("testUser", "testUser1"); Configuration conf = new Configuration(); conf.set(ConfigurationKeys.KUBE2HADOOP_AUTHENTICATOR_BLACKLISTED_USERS, "testUser, testUser1"); List<String> actualBlackListedUsers = authenticator.getBlackListedSuperUsers(conf); Assert.assertEquals(actualBlackListedUsers, expectedBlackListedUsers); }
List<String> getBlackListedSuperUsers(Configuration conf) { return Arrays.asList( conf.get(ConfigurationKeys.KUBE2HADOOP_AUTHENTICATOR_BLACKLISTED_USERS, "") .split("\\s*,\\s*")); }
KubernetesAuthenticator implements Authenticator { List<String> getBlackListedSuperUsers(Configuration conf) { return Arrays.asList( conf.get(ConfigurationKeys.KUBE2HADOOP_AUTHENTICATOR_BLACKLISTED_USERS, "") .split("\\s*,\\s*")); } }
KubernetesAuthenticator implements Authenticator { List<String> getBlackListedSuperUsers(Configuration conf) { return Arrays.asList( conf.get(ConfigurationKeys.KUBE2HADOOP_AUTHENTICATOR_BLACKLISTED_USERS, "") .split("\\s*,\\s*")); } KubernetesAuthenticator(Configuration conf); }
KubernetesAuthenticator implements Authenticator { List<String> getBlackListedSuperUsers(Configuration conf) { return Arrays.asList( conf.get(ConfigurationKeys.KUBE2HADOOP_AUTHENTICATOR_BLACKLISTED_USERS, "") .split("\\s*,\\s*")); } KubernetesAuthenticator(Configuration conf); @Override String getAuthenticatedUserID(AuthenticatorParameters params); @Override Configuration getConfiguration(); }
KubernetesAuthenticator implements Authenticator { List<String> getBlackListedSuperUsers(Configuration conf) { return Arrays.asList( conf.get(ConfigurationKeys.KUBE2HADOOP_AUTHENTICATOR_BLACKLISTED_USERS, "") .split("\\s*,\\s*")); } KubernetesAuthenticator(Configuration conf); @Override String getAuthenticatedUserID(AuthenticatorParameters params); @Override Configuration getConfiguration();  }