本文整理了Java中org.apache.hadoop.hbase.zookeeper.ZKNodeTracker.nodeDataChanged()
方法的一些代码示例,展示了ZKNodeTracker.nodeDataChanged()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ZKNodeTracker.nodeDataChanged()
方法的具体详情如下:
包路径:org.apache.hadoop.hbase.zookeeper.ZKNodeTracker
类名称:ZKNodeTracker
方法名:nodeDataChanged
暂无
代码示例来源:origin: apache/hbase
/**
* Set the switch on/off
* @param enabled switch enabled or not?
* @throws KeeperException keepException will be thrown out
*/
public void setSwitchEnabled(boolean enabled) throws KeeperException {
byte [] upData = toByteArray(enabled);
try {
ZKUtil.setData(watcher, node, upData);
} catch(KeeperException.NoNodeException nne) {
ZKUtil.createAndWatch(watcher, node, upData);
}
super.nodeDataChanged(node);
}
代码示例来源:origin: apache/hbase
/**
* Set the balancer on/off.
*
* @param balancerOn true if the balancher should be on, false otherwise
* @throws KeeperException if a ZooKeeper operation fails
*/
public void setBalancerOn(boolean balancerOn) throws KeeperException {
byte [] upData = toByteArray(balancerOn);
try {
ZKUtil.setData(watcher, watcher.getZNodePaths().balancerZNode, upData);
} catch(KeeperException.NoNodeException nne) {
ZKUtil.createAndWatch(watcher, watcher.getZNodePaths().balancerZNode, upData);
}
super.nodeDataChanged(watcher.getZNodePaths().balancerZNode);
}
代码示例来源:origin: apache/hbase
/**
* Set region normalizer on/off
* @param normalizerOn whether normalizer should be on or off
* @throws KeeperException if a ZooKeeper operation fails
*/
public void setNormalizerOn(boolean normalizerOn) throws KeeperException {
byte [] upData = toByteArray(normalizerOn);
try {
ZKUtil.setData(watcher, watcher.getZNodePaths().regionNormalizerZNode, upData);
} catch(KeeperException.NoNodeException nne) {
ZKUtil.createAndWatch(watcher, watcher.getZNodePaths().regionNormalizerZNode, upData);
}
super.nodeDataChanged(watcher.getZNodePaths().regionNormalizerZNode);
}
代码示例来源:origin: org.apache.hbase/hbase-zookeeper
/**
* Set region normalizer on/off
* @param normalizerOn whether normalizer should be on or off
* @throws KeeperException if a ZooKeeper operation fails
*/
public void setNormalizerOn(boolean normalizerOn) throws KeeperException {
byte [] upData = toByteArray(normalizerOn);
try {
ZKUtil.setData(watcher, watcher.getZNodePaths().regionNormalizerZNode, upData);
} catch(KeeperException.NoNodeException nne) {
ZKUtil.createAndWatch(watcher, watcher.getZNodePaths().regionNormalizerZNode, upData);
}
super.nodeDataChanged(watcher.getZNodePaths().regionNormalizerZNode);
}
代码示例来源:origin: org.apache.hbase/hbase-zookeeper
/**
* Set the balancer on/off.
*
* @param balancerOn true if the balancher should be on, false otherwise
* @throws KeeperException if a ZooKeeper operation fails
*/
public void setBalancerOn(boolean balancerOn) throws KeeperException {
byte [] upData = toByteArray(balancerOn);
try {
ZKUtil.setData(watcher, watcher.getZNodePaths().balancerZNode, upData);
} catch(KeeperException.NoNodeException nne) {
ZKUtil.createAndWatch(watcher, watcher.getZNodePaths().balancerZNode, upData);
}
super.nodeDataChanged(watcher.getZNodePaths().balancerZNode);
}
内容来源于网络,如有侵权,请联系作者删除!