public class ReportingZooKeeperClient extends Object implements ZooKeeperClient
ZooKeeperClient.| Constructor and Description |
|---|
ReportingZooKeeperClient(ZooKeeperClient client,
ZooKeeperModelReporter reporter,
String tag) |
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
void |
create(String path) |
void |
createAndSetData(String path,
byte[] data) |
void |
createWithMode(String path,
org.apache.zookeeper.CreateMode mode) |
void |
delete(String path) |
void |
delete(String path,
int version) |
void |
deleteRecursive(String path) |
void |
ensurePath(String path) |
void |
ensurePath(String path,
boolean excludingLast) |
void |
ensurePathAndSetData(String path,
byte[] data)
Ensure a path exists.
|
org.apache.zookeeper.data.Stat |
exists(String path) |
List<org.apache.zookeeper.data.ACL> |
getAcl(String path) |
List<String> |
getChildren(String path) |
org.apache.curator.framework.listen.Listenable<org.apache.curator.framework.state.ConnectionStateListener> |
getConnectionStateListenable() |
org.apache.curator.framework.CuratorFramework |
getCuratorFramework() |
byte[] |
getData(String path) |
Node |
getNode(String path) |
org.apache.zookeeper.ZooKeeper.States |
getState() |
List<String> |
listRecursive(String path) |
<T> PersistentPathChildrenCache<T> |
pathChildrenCache(String path,
Path snapshotFile,
com.fasterxml.jackson.databind.JavaType valueType) |
org.apache.curator.framework.recipes.nodes.PersistentEphemeralNode |
persistentEphemeralNode(String path,
org.apache.curator.framework.recipes.nodes.PersistentEphemeralNode.Mode mode,
byte[] data) |
void |
setAcl(String path,
List<org.apache.zookeeper.data.ACL> aclList) |
void |
setData(String path,
byte[] bytes) |
void |
start() |
org.apache.zookeeper.data.Stat |
stat(String path) |
Collection<org.apache.curator.framework.api.transaction.CuratorTransactionResult> |
transaction(List<ZooKeeperOperation> operations) |
Collection<org.apache.curator.framework.api.transaction.CuratorTransactionResult> |
transaction(ZooKeeperOperation... operations) |
public ReportingZooKeeperClient(ZooKeeperClient client, ZooKeeperModelReporter reporter, String tag)
public void ensurePath(String path) throws org.apache.zookeeper.KeeperException
ensurePath in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionpublic void ensurePath(String path, boolean excludingLast) throws org.apache.zookeeper.KeeperException
ensurePath in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionpublic void ensurePathAndSetData(String path, byte[] data) throws org.apache.zookeeper.KeeperException
ZooKeeperClientensurePathAndSetData in interface ZooKeeperClientpath - The path to ensure exists.data - The data to write at the base of the path, if it does not exist.org.apache.zookeeper.KeeperExceptionpublic byte[] getData(String path) throws org.apache.zookeeper.KeeperException
getData in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionpublic List<String> getChildren(String path) throws org.apache.zookeeper.KeeperException
getChildren in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionpublic void delete(String path) throws org.apache.zookeeper.KeeperException
delete in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionpublic void delete(String path, int version) throws org.apache.zookeeper.KeeperException
delete in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionpublic void setData(String path, byte[] bytes) throws org.apache.zookeeper.KeeperException
setData in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionpublic void createAndSetData(String path, byte[] data) throws org.apache.zookeeper.KeeperException
createAndSetData in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionpublic void createWithMode(String path, org.apache.zookeeper.CreateMode mode) throws org.apache.zookeeper.KeeperException
createWithMode in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionpublic org.apache.zookeeper.data.Stat stat(String path) throws org.apache.zookeeper.KeeperException
stat in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionpublic void deleteRecursive(String path) throws org.apache.zookeeper.KeeperException
deleteRecursive in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionpublic List<String> listRecursive(String path) throws org.apache.zookeeper.KeeperException
listRecursive in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionpublic void create(String path) throws org.apache.zookeeper.KeeperException
create in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionpublic <T> PersistentPathChildrenCache<T> pathChildrenCache(String path, Path snapshotFile, com.fasterxml.jackson.databind.JavaType valueType) throws IOException, InterruptedException
pathChildrenCache in interface ZooKeeperClientIOExceptionInterruptedExceptionpublic Collection<org.apache.curator.framework.api.transaction.CuratorTransactionResult> transaction(List<ZooKeeperOperation> operations) throws org.apache.zookeeper.KeeperException
transaction in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionpublic Collection<org.apache.curator.framework.api.transaction.CuratorTransactionResult> transaction(ZooKeeperOperation... operations) throws org.apache.zookeeper.KeeperException
transaction in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionpublic Node getNode(String path) throws org.apache.zookeeper.KeeperException
getNode in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionpublic org.apache.zookeeper.data.Stat exists(String path) throws org.apache.zookeeper.KeeperException
exists in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionpublic org.apache.curator.framework.listen.Listenable<org.apache.curator.framework.state.ConnectionStateListener> getConnectionStateListenable()
getConnectionStateListenable in interface ZooKeeperClientpublic org.apache.zookeeper.ZooKeeper.States getState()
throws org.apache.zookeeper.KeeperException
getState in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionpublic org.apache.curator.framework.recipes.nodes.PersistentEphemeralNode persistentEphemeralNode(String path, org.apache.curator.framework.recipes.nodes.PersistentEphemeralNode.Mode mode, byte[] data)
persistentEphemeralNode in interface ZooKeeperClientpublic void start()
start in interface ZooKeeperClientpublic void close()
close in interface ZooKeeperClientpublic org.apache.curator.framework.CuratorFramework getCuratorFramework()
getCuratorFramework in interface ZooKeeperClientpublic void setAcl(String path, List<org.apache.zookeeper.data.ACL> aclList) throws org.apache.zookeeper.KeeperException
setAcl in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionpublic List<org.apache.zookeeper.data.ACL> getAcl(String path) throws org.apache.zookeeper.KeeperException
getAcl in interface ZooKeeperClientorg.apache.zookeeper.KeeperExceptionCopyright © 2017. All rights reserved.