Package | Description |
---|---|
org.apache.zookeeper | |
org.apache.zookeeper.server |
ZooKeeper server theory of operation
ZooKeeperServer is designed to work in standalone mode and also
be extensible so that it can be used to implement the quorum based
version of ZooKeeper.
|
Modifier and Type | Method and Description |
---|---|
static KeeperException |
KeeperException.create(int code)
Deprecated.
deprecated in 3.1.0, use
create(Code)
instead |
static KeeperException |
KeeperException.create(int code,
String path)
Deprecated.
deprecated in 3.1.0, use
create(Code, String)
instead |
static KeeperException |
KeeperException.create(KeeperException.Code code)
All non-specific keeper exceptions should be constructed via
this factory method in order to guarantee consistency in error
codes and such.
|
static KeeperException |
KeeperException.create(KeeperException.Code code,
String path)
All non-specific keeper exceptions should be constructed via
this factory method in order to guarantee consistency in error
codes and such.
|
Modifier and Type | Method and Description |
---|---|
List<OpResult> |
Transaction.commit() |
String |
ZooKeeper.create(String path,
byte[] data,
List<ACL> acl,
CreateMode createMode)
Create a node with the given path.
|
static boolean |
ZooKeeperMain.createQuota(ZooKeeper zk,
String path,
long bytes,
int numNodes)
this method creates a quota node for the path
|
void |
ZooKeeper.delete(String path,
int version)
Delete the node with the given path.
|
static void |
ZKUtil.deleteRecursive(ZooKeeper zk,
String pathRoot)
Recursively delete the node with the given path.
|
static void |
ZKUtil.deleteRecursive(ZooKeeper zk,
String pathRoot,
AsyncCallback.VoidCallback cb,
Object ctx)
Recursively delete the node with the given path.
|
static boolean |
ZooKeeperMain.delQuota(ZooKeeper zk,
String path,
boolean bytes,
boolean numNodes)
this method deletes quota for a node.
|
void |
ZooKeeperMain.executeLine(String line) |
Stat |
ZooKeeper.exists(String path,
boolean watch)
Return the stat of the node of the given path.
|
Stat |
ZooKeeper.exists(String path,
Watcher watcher)
Return the stat of the node of the given path.
|
static CreateMode |
CreateMode.fromFlag(int flag)
Map an integer value to a CreateMode value
|
List<ACL> |
ZooKeeper.getACL(String path,
Stat stat)
Return the ACL and stat of the node of the given path.
|
List<String> |
ZooKeeper.getChildren(String path,
boolean watch)
Return the list of the children of the node of the given path.
|
List<String> |
ZooKeeper.getChildren(String path,
boolean watch,
Stat stat)
For the given znode path return the stat and children list.
|
List<String> |
ZooKeeper.getChildren(String path,
Watcher watcher)
Return the list of the children of the node of the given path.
|
List<String> |
ZooKeeper.getChildren(String path,
Watcher watcher,
Stat stat)
For the given znode path return the stat and children list.
|
byte[] |
ZooKeeper.getData(String path,
boolean watch,
Stat stat)
Return the data and the stat of the node of the given path.
|
byte[] |
ZooKeeper.getData(String path,
Watcher watcher,
Stat stat)
Return the data and the stat of the node of the given path.
|
static List<String> |
ZKUtil.listSubTreeBFS(ZooKeeper zk,
String pathRoot)
BFS Traversal of the system under pathRoot, with the entries in the list, in the
same order as that of the traversal.
|
static void |
ZooKeeperMain.main(String[] args) |
List<OpResult> |
ZooKeeper.multi(Iterable<Op> ops)
Executes multiple ZooKeeper operations or none of them.
|
protected List<OpResult> |
ZooKeeper.multiInternal(MultiTransactionRecord request) |
protected boolean |
ZooKeeperMain.processCmd(org.apache.zookeeper.ZooKeeperMain.MyCommandOptions co) |
protected boolean |
ZooKeeperMain.processZKCmd(org.apache.zookeeper.ZooKeeperMain.MyCommandOptions co) |
Stat |
ZooKeeper.setACL(String path,
List<ACL> acl,
int version)
Set the ACL for the node of the given path if such a node exists and the
given version matches the version of the node.
|
Stat |
ZooKeeper.setData(String path,
byte[] data,
int version)
Set the data for the node of the given path if such a node exists and the
given version matches the version of the node (if the given version is
-1, it matches any node's versions).
|
Modifier and Type | Method and Description |
---|---|
KeeperException |
Request.getException() |
Modifier and Type | Method and Description |
---|---|
void |
Request.setException(KeeperException e) |
Modifier and Type | Method and Description |
---|---|
protected void |
PrepRequestProcessor.pRequest2Txn(int type,
long zxid,
Request request,
org.apache.jute.Record record,
boolean deserialize)
This method will be called inside the ProcessRequestThread, which is a
singleton, so there will be a single thread calling this code.
|
Copyright © 2017 The Apache Software Foundation