HBASE-19114 addendum. Split out o.a.h.h.zookeeper from hbase-server and hbase-client. Ruby scripts also used ZooKeeperWatcher.

Signed-off-by: Apekshit Sharma <appy@apache.org>
This commit is contained in:
Csaba Skrabak 2018-03-02 11:09:50 -08:00 committed by Apekshit Sharma
parent 2b1b2c8490
commit ff550edabf
2 changed files with 5 additions and 5 deletions

View File

@ -85,7 +85,7 @@ def addServers(_options, hostOrServers)
config = HBaseConfiguration.create
servers = getServerNames(hostOrServers, config)
zkw = org.apache.hadoop.hbase.zookeeper.ZooKeeperWatcher.new(config, 'draining_servers', nil)
zkw = org.apache.hadoop.hbase.zookeeper.ZKWatcher.new(config, 'draining_servers', nil)
parentZnode = zkw.znodePaths.drainingZNode
begin
@ -102,7 +102,7 @@ def removeServers(_options, hostOrServers)
config = HBaseConfiguration.create
servers = getServerNames(hostOrServers, config)
zkw = org.apache.hadoop.hbase.zookeeper.ZooKeeperWatcher.new(config, 'draining_servers', nil)
zkw = org.apache.hadoop.hbase.zookeeper.ZKWatcher.new(config, 'draining_servers', nil)
parentZnode = zkw.znodePaths.drainingZNode
begin
@ -119,7 +119,7 @@ end
def listServers(_options)
config = HBaseConfiguration.create
zkw = org.apache.hadoop.hbase.zookeeper.ZooKeeperWatcher.new(config, 'draining_servers', nil)
zkw = org.apache.hadoop.hbase.zookeeper.ZKWatcher.new(config, 'draining_servers', nil)
parentZnode = zkw.znodePaths.drainingZNode
servers = ZKUtil.listChildrenNoWatch(zkw, parentZnode)

View File

@ -20,7 +20,7 @@
include Java
java_import org.apache.hadoop.hbase.HBaseConfiguration
java_import org.apache.hadoop.hbase.ServerName
java_import org.apache.hadoop.hbase.zookeeper.ZooKeeperWatcher
java_import org.apache.hadoop.hbase.zookeeper.ZKWatcher
java_import org.apache.hadoop.hbase.zookeeper.MasterAddressTracker
# disable debug/info logging on this script for clarity
@ -30,7 +30,7 @@ org.apache.log4j.Logger.getLogger('org.apache.zookeeper').setLevel(log_level)
config = HBaseConfiguration.create
zk = ZooKeeperWatcher.new(config, 'get-active-master', nil)
zk = ZKWatcher.new(config, 'get-active-master', nil)
begin
puts MasterAddressTracker.getMasterAddress(zk).getHostname
ensure