Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- try {
- String instanceName = "tcri";
- String zooServers = "10.57.19.131";
- Instance inst = new ZooKeeperInstance(instanceName, zooServers);
- AuthenticationToken authToken = new PasswordToken("password");
- System.out.println("Starting connection...");
- Connector conn = inst.getConnector("root", authToken);
- } catch (Exception e) {
- System.out.println(e);
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement