Skip to content

Commit 523bb2e

Browse files
aajisakaiwasakims
authored andcommitted
YARN-9783. Remove low-level zookeeper test to be able to build Hadoop against zookeeper 3.5.5. Contributed by Mate Szalay-Beko.
(cherry picked from commit dc0acce)
1 parent c64eda0 commit 523bb2e

File tree

1 file changed

+0
-34
lines changed
  • hadoop-yarn-project/hadoop-yarn/hadoop-yarn-registry/src/test/java/org/apache/hadoop/registry/secure

1 file changed

+0
-34
lines changed

hadoop-yarn-project/hadoop-yarn/hadoop-yarn-registry/src/test/java/org/apache/hadoop/registry/secure/TestSecureRegistry.java

Lines changed: 0 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -24,16 +24,12 @@
2424
import org.apache.hadoop.registry.client.impl.zk.CuratorService;
2525
import org.apache.hadoop.registry.client.impl.zk.RegistrySecurity;
2626
import org.apache.zookeeper.CreateMode;
27-
import org.apache.zookeeper.Login;
28-
import org.apache.zookeeper.server.ZooKeeperSaslServer;
29-
import org.apache.zookeeper.server.auth.SaslServerCallbackHandler;
3027
import org.junit.After;
3128
import org.junit.Before;
3229
import org.junit.Test;
3330
import org.slf4j.Logger;
3431
import org.slf4j.LoggerFactory;
3532

36-
import javax.security.auth.login.AppConfigurationEntry;
3733
import javax.security.auth.login.LoginContext;
3834

3935
import static org.apache.hadoop.registry.client.api.RegistryConstants.*;
@@ -58,36 +54,6 @@ public void afterTestSecureZKService() throws Throwable {
5854
RegistrySecurity.clearZKSaslClientProperties();
5955
}
6056

61-
/**
62-
* this is a cut and paste of some of the ZK internal code that was
63-
* failing on windows and swallowing its exceptions
64-
*/
65-
@Test
66-
public void testLowlevelZKSaslLogin() throws Throwable {
67-
RegistrySecurity.bindZKToServerJAASContext(ZOOKEEPER_SERVER_CONTEXT);
68-
String serverSection =
69-
System.getProperty(ZooKeeperSaslServer.LOGIN_CONTEXT_NAME_KEY,
70-
ZooKeeperSaslServer.DEFAULT_LOGIN_CONTEXT_NAME);
71-
assertEquals(ZOOKEEPER_SERVER_CONTEXT, serverSection);
72-
73-
AppConfigurationEntry entries[];
74-
entries = javax.security.auth.login.Configuration.getConfiguration()
75-
.getAppConfigurationEntry(
76-
serverSection);
77-
78-
assertNotNull("null entries", entries);
79-
80-
SaslServerCallbackHandler saslServerCallbackHandler =
81-
new SaslServerCallbackHandler(
82-
javax.security.auth.login.Configuration.getConfiguration());
83-
Login login = new Login(serverSection, saslServerCallbackHandler);
84-
try {
85-
login.startThreadIfNeeded();
86-
} finally {
87-
login.shutdown();
88-
}
89-
}
90-
9157
@Test
9258
public void testCreateSecureZK() throws Throwable {
9359
startSecureZK();

0 commit comments

Comments
 (0)