org.apache.zookeeper.server.quorum
Class QuorumPeerConfig
java.lang.Object
org.apache.zookeeper.server.quorum.QuorumPeerConfig
public class QuorumPeerConfig
- extends java.lang.Object
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
clientPortAddress
protected java.net.InetSocketAddress clientPortAddress
dataDir
protected java.lang.String dataDir
dataLogDir
protected java.lang.String dataLogDir
tickTime
protected int tickTime
maxClientCnxns
protected int maxClientCnxns
minSessionTimeout
protected int minSessionTimeout
- defaults to -1 if not set explicitly
maxSessionTimeout
protected int maxSessionTimeout
- defaults to -1 if not set explicitly
initLimit
protected int initLimit
syncLimit
protected int syncLimit
electionAlg
protected int electionAlg
electionPort
protected int electionPort
servers
protected final java.util.HashMap<java.lang.Long,QuorumPeer.QuorumServer> servers
observers
protected final java.util.HashMap<java.lang.Long,QuorumPeer.QuorumServer> observers
serverId
protected long serverId
serverWeight
protected java.util.HashMap<java.lang.Long,java.lang.Long> serverWeight
serverGroup
protected java.util.HashMap<java.lang.Long,java.lang.Long> serverGroup
numGroups
protected int numGroups
quorumVerifier
protected QuorumVerifier quorumVerifier
peerType
protected QuorumPeer.LearnerType peerType
QuorumPeerConfig
public QuorumPeerConfig()
parse
public void parse(java.lang.String path)
throws QuorumPeerConfig.ConfigException
- Parse a ZooKeeper configuration file
- Parameters:
path
- the patch of the configuration file
- Throws:
QuorumPeerConfig.ConfigException
- error processing configuration
parseProperties
public void parseProperties(java.util.Properties zkProp)
throws java.io.IOException,
QuorumPeerConfig.ConfigException
- Parse config from a Properties.
- Parameters:
zkProp
- Properties to parse from.
- Throws:
java.io.IOException
QuorumPeerConfig.ConfigException
getClientPortAddress
public java.net.InetSocketAddress getClientPortAddress()
getDataDir
public java.lang.String getDataDir()
getDataLogDir
public java.lang.String getDataLogDir()
getTickTime
public int getTickTime()
getMaxClientCnxns
public int getMaxClientCnxns()
getMinSessionTimeout
public int getMinSessionTimeout()
getMaxSessionTimeout
public int getMaxSessionTimeout()
getInitLimit
public int getInitLimit()
getSyncLimit
public int getSyncLimit()
getElectionAlg
public int getElectionAlg()
getElectionPort
public int getElectionPort()
getQuorumVerifier
public QuorumVerifier getQuorumVerifier()
getServers
public java.util.Map<java.lang.Long,QuorumPeer.QuorumServer> getServers()
getServerId
public long getServerId()
isDistributed
public boolean isDistributed()
getPeerType
public QuorumPeer.LearnerType getPeerType()
Copyright © 2011 The Apache Software Foundation