@Test public void testMultipleExplicitHosts() { String server = "server", host1 = "host1", host2 = "host2", host3 = "host3"; setValidHosts(Joiner.on(',').join(host1, host2, host3)); setValidUsers(server, "*"); UserImpersonation impersonation = new UserImpersonation(conf); UsersWithHosts uwh = impersonation.get(server); assertNotNull(uwh); assertFalse(uwh.acceptsAllHosts()); assertTrue(uwh.acceptsAllUsers()); assertNotEquals(AlwaysTrueSet.class, uwh.getHosts().getClass()); assertEquals(AlwaysTrueSet.class, uwh.getUsers().getClass()); assertTrue(uwh.getHosts().contains(host1)); assertTrue(uwh.getHosts().contains(host2)); assertTrue(uwh.getHosts().contains(host3)); assertFalse(uwh.getHosts().contains("other_host")); }
public UsersWithHosts get(String remoteUser) { return proxyUsers.get(remoteUser); }
UserImpersonation { public UsersWithHosts get(String remoteUser) { return proxyUsers.get(remoteUser); } }
UserImpersonation { public UsersWithHosts get(String remoteUser) { return proxyUsers.get(remoteUser); } UserImpersonation(AccumuloConfiguration conf); }
UserImpersonation { public UsersWithHosts get(String remoteUser) { return proxyUsers.get(remoteUser); } UserImpersonation(AccumuloConfiguration conf); UsersWithHosts get(String remoteUser); }
UserImpersonation { public UsersWithHosts get(String remoteUser) { return proxyUsers.get(remoteUser); } UserImpersonation(AccumuloConfiguration conf); UsersWithHosts get(String remoteUser);  }