org.apache.blur.zookeeper
Class ZooKeeperClient

java.lang.Object
  extended by org.apache.zookeeper.ZooKeeper
      extended by org.apache.blur.zookeeper.ZooKeeperClient

public class ZooKeeperClient
extends org.apache.zookeeper.ZooKeeper


Nested Class Summary
 
Nested classes/interfaces inherited from class org.apache.zookeeper.ZooKeeper
org.apache.zookeeper.ZooKeeper.States
 
Field Summary
 
Fields inherited from class org.apache.zookeeper.ZooKeeper
ZOOKEEPER_CLIENT_CNXN_SOCKET
 
Constructor Summary
ZooKeeperClient(String connectString, int sessionTimeout, org.apache.zookeeper.Watcher watcher)
           
ZooKeeperClient(String connectString, int sessionTimeout, org.apache.zookeeper.Watcher watcher, boolean canBeReadOnly)
           
ZooKeeperClient(String connectString, int sessionTimeout, org.apache.zookeeper.Watcher watcher, long sessionId, byte[] sessionPasswd)
           
ZooKeeperClient(String connectString, int sessionTimeout, org.apache.zookeeper.Watcher watcher, long sessionId, byte[] sessionPasswd, boolean canBeReadOnly)
           
 
Method Summary
 String create(String path, byte[] data, List<org.apache.zookeeper.data.ACL> acl, org.apache.zookeeper.CreateMode createMode)
           
 void delete(String path, int version)
           
<T> T
execute(org.apache.blur.zookeeper.ZooKeeperClient.ZKExecutor<T> executor)
           
 org.apache.zookeeper.data.Stat exists(String path, boolean watch)
           
 org.apache.zookeeper.data.Stat exists(String path, org.apache.zookeeper.Watcher watcher)
           
 List<org.apache.zookeeper.data.ACL> getACL(String path, org.apache.zookeeper.data.Stat stat)
           
 List<String> getChildren(String path, boolean watch)
           
 List<String> getChildren(String path, boolean watch, org.apache.zookeeper.data.Stat stat)
           
 List<String> getChildren(String path, org.apache.zookeeper.Watcher watcher)
           
 List<String> getChildren(String path, org.apache.zookeeper.Watcher watcher, org.apache.zookeeper.data.Stat stat)
           
 byte[] getData(String path, boolean watch, org.apache.zookeeper.data.Stat stat)
           
 byte[] getData(String path, org.apache.zookeeper.Watcher watcher, org.apache.zookeeper.data.Stat stat)
           
 List<org.apache.zookeeper.OpResult> multi(Iterable<org.apache.zookeeper.Op> ops)
           
 org.apache.zookeeper.data.Stat setACL(String path, List<org.apache.zookeeper.data.ACL> acl, int version)
           
 org.apache.zookeeper.data.Stat setData(String path, byte[] data, int version)
           
 
Methods inherited from class org.apache.zookeeper.ZooKeeper
addAuthInfo, close, create, delete, exists, exists, getACL, getChildren, getChildren, getChildren, getChildren, getData, getData, getSaslClient, getSessionId, getSessionPasswd, getSessionTimeout, getState, register, setACL, setData, sync, toString, transaction
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ZooKeeperClient

public ZooKeeperClient(String connectString,
                       int sessionTimeout,
                       org.apache.zookeeper.Watcher watcher)
                throws IOException
Throws:
IOException

ZooKeeperClient

public ZooKeeperClient(String connectString,
                       int sessionTimeout,
                       org.apache.zookeeper.Watcher watcher,
                       boolean canBeReadOnly)
                throws IOException
Throws:
IOException

ZooKeeperClient

public ZooKeeperClient(String connectString,
                       int sessionTimeout,
                       org.apache.zookeeper.Watcher watcher,
                       long sessionId,
                       byte[] sessionPasswd,
                       boolean canBeReadOnly)
                throws IOException
Throws:
IOException

ZooKeeperClient

public ZooKeeperClient(String connectString,
                       int sessionTimeout,
                       org.apache.zookeeper.Watcher watcher,
                       long sessionId,
                       byte[] sessionPasswd)
                throws IOException
Throws:
IOException
Method Detail

execute

public <T> T execute(org.apache.blur.zookeeper.ZooKeeperClient.ZKExecutor<T> executor)
          throws org.apache.zookeeper.KeeperException,
                 InterruptedException
Throws:
org.apache.zookeeper.KeeperException
InterruptedException

create

public String create(String path,
                     byte[] data,
                     List<org.apache.zookeeper.data.ACL> acl,
                     org.apache.zookeeper.CreateMode createMode)
              throws org.apache.zookeeper.KeeperException,
                     InterruptedException
Overrides:
create in class org.apache.zookeeper.ZooKeeper
Throws:
org.apache.zookeeper.KeeperException
InterruptedException

delete

public void delete(String path,
                   int version)
            throws InterruptedException,
                   org.apache.zookeeper.KeeperException
Overrides:
delete in class org.apache.zookeeper.ZooKeeper
Throws:
InterruptedException
org.apache.zookeeper.KeeperException

multi

public List<org.apache.zookeeper.OpResult> multi(Iterable<org.apache.zookeeper.Op> ops)
                                          throws InterruptedException,
                                                 org.apache.zookeeper.KeeperException
Overrides:
multi in class org.apache.zookeeper.ZooKeeper
Throws:
InterruptedException
org.apache.zookeeper.KeeperException

exists

public org.apache.zookeeper.data.Stat exists(String path,
                                             org.apache.zookeeper.Watcher watcher)
                                      throws org.apache.zookeeper.KeeperException,
                                             InterruptedException
Overrides:
exists in class org.apache.zookeeper.ZooKeeper
Throws:
org.apache.zookeeper.KeeperException
InterruptedException

exists

public org.apache.zookeeper.data.Stat exists(String path,
                                             boolean watch)
                                      throws org.apache.zookeeper.KeeperException,
                                             InterruptedException
Overrides:
exists in class org.apache.zookeeper.ZooKeeper
Throws:
org.apache.zookeeper.KeeperException
InterruptedException

getData

public byte[] getData(String path,
                      org.apache.zookeeper.Watcher watcher,
                      org.apache.zookeeper.data.Stat stat)
               throws org.apache.zookeeper.KeeperException,
                      InterruptedException
Overrides:
getData in class org.apache.zookeeper.ZooKeeper
Throws:
org.apache.zookeeper.KeeperException
InterruptedException

getData

public byte[] getData(String path,
                      boolean watch,
                      org.apache.zookeeper.data.Stat stat)
               throws org.apache.zookeeper.KeeperException,
                      InterruptedException
Overrides:
getData in class org.apache.zookeeper.ZooKeeper
Throws:
org.apache.zookeeper.KeeperException
InterruptedException

setData

public org.apache.zookeeper.data.Stat setData(String path,
                                              byte[] data,
                                              int version)
                                       throws org.apache.zookeeper.KeeperException,
                                              InterruptedException
Overrides:
setData in class org.apache.zookeeper.ZooKeeper
Throws:
org.apache.zookeeper.KeeperException
InterruptedException

getACL

public List<org.apache.zookeeper.data.ACL> getACL(String path,
                                                  org.apache.zookeeper.data.Stat stat)
                                           throws org.apache.zookeeper.KeeperException,
                                                  InterruptedException
Overrides:
getACL in class org.apache.zookeeper.ZooKeeper
Throws:
org.apache.zookeeper.KeeperException
InterruptedException

setACL

public org.apache.zookeeper.data.Stat setACL(String path,
                                             List<org.apache.zookeeper.data.ACL> acl,
                                             int version)
                                      throws org.apache.zookeeper.KeeperException,
                                             InterruptedException
Overrides:
setACL in class org.apache.zookeeper.ZooKeeper
Throws:
org.apache.zookeeper.KeeperException
InterruptedException

getChildren

public List<String> getChildren(String path,
                                org.apache.zookeeper.Watcher watcher)
                         throws org.apache.zookeeper.KeeperException,
                                InterruptedException
Overrides:
getChildren in class org.apache.zookeeper.ZooKeeper
Throws:
org.apache.zookeeper.KeeperException
InterruptedException

getChildren

public List<String> getChildren(String path,
                                boolean watch)
                         throws org.apache.zookeeper.KeeperException,
                                InterruptedException
Overrides:
getChildren in class org.apache.zookeeper.ZooKeeper
Throws:
org.apache.zookeeper.KeeperException
InterruptedException

getChildren

public List<String> getChildren(String path,
                                org.apache.zookeeper.Watcher watcher,
                                org.apache.zookeeper.data.Stat stat)
                         throws org.apache.zookeeper.KeeperException,
                                InterruptedException
Overrides:
getChildren in class org.apache.zookeeper.ZooKeeper
Throws:
org.apache.zookeeper.KeeperException
InterruptedException

getChildren

public List<String> getChildren(String path,
                                boolean watch,
                                org.apache.zookeeper.data.Stat stat)
                         throws org.apache.zookeeper.KeeperException,
                                InterruptedException
Overrides:
getChildren in class org.apache.zookeeper.ZooKeeper
Throws:
org.apache.zookeeper.KeeperException
InterruptedException


Copyright © 2012-2014 The Apache Software Foundation. All Rights Reserved.