@InterfaceAudience.Private public class RegionServerTracker extends ZKListener
ServerManager.expireServer(ServerName)watcher| Constructor and Description |
|---|
RegionServerTracker(ZKWatcher watcher,
MasterServices server,
ServerManager serverManager) |
| Modifier and Type | Method and Description |
|---|---|
void |
nodeChildrenChanged(String path) |
void |
start(Set<ServerName> deadServersFromPE,
Set<ServerName> liveServersFromWALDir)
Starts the tracking of online RegionServers.
|
void |
stop() |
getWatcher, nodeCreated, nodeDataChanged, nodeDeletedpublic RegionServerTracker(ZKWatcher watcher, MasterServices server, ServerManager serverManager)
public void start(Set<ServerName> deadServersFromPE, Set<ServerName> liveServersFromWALDir) throws org.apache.zookeeper.KeeperException, IOException
ServerManager. If a
region server is dead between the crash of the previous master instance and the start of the
current master instance, we will schedule a SCP for it. This is done in
ServerManager.findOutDeadServersAndProcess(Set, Set), we call it here under the lock
protection to prevent concurrency issues with server expiration operation.deadServersFromPE - the region servers which already have SCP associated.liveServersFromWALDir - the live region servers from wal directory.org.apache.zookeeper.KeeperExceptionIOExceptionpublic void stop()
public void nodeChildrenChanged(String path)
nodeChildrenChanged in class ZKListenerCopyright © 2007–2018 The Apache Software Foundation. All rights reserved.