org.apache.blur.manager.indexserver
Class SafeMode
java.lang.Object
org.apache.blur.zookeeper.ZooKeeperLockManager
org.apache.blur.manager.indexserver.SafeMode
public class SafeMode
- extends ZooKeeperLockManager
This class controls the startup of the cluster. Basically the first node
online waits until there is no more nodes that have started. The period that
is required to have no activity is the waittime passed in through the
constructor. If a new node comes online while the leader is waiting, the wait
starts over. Once the wait period has been exhausted the cluster is to be
settled and can now come online.
Constructor Summary |
SafeMode(org.apache.zookeeper.ZooKeeper zooKeeper,
String lockPath,
String nodePath,
TimeUnit waitTimeUnit,
long waitTime,
TimeUnit duplicateNodeTimeoutTimeUnit,
long duplicateNodeTimeout,
int minimumNumberOfNodes)
|
STARTUP
public static final String STARTUP
- See Also:
- Constant Field Values
SETUP
public static final String SETUP
- See Also:
- Constant Field Values
SafeMode
public SafeMode(org.apache.zookeeper.ZooKeeper zooKeeper,
String lockPath,
String nodePath,
TimeUnit waitTimeUnit,
long waitTime,
TimeUnit duplicateNodeTimeoutTimeUnit,
long duplicateNodeTimeout,
int minimumNumberOfNodes)
registerNode
public void registerNode(String node,
byte[] data)
throws org.apache.zookeeper.KeeperException,
InterruptedException
- Throws:
org.apache.zookeeper.KeeperException
InterruptedException
Copyright © 2012-2014 The Apache Software Foundation. All Rights Reserved.