public class LeaderZooKeeperServer extends QuorumZooKeeperServer
ZooKeeperServer.MissingSessionException, ZooKeeperServer.Stateself, upgradeableSessionTrackerALLOW_SASL_FAILED_CLIENTS, CLOSE_SESSION_TXN_ENABLED, DEFAULT_STARTING_BUFFER_SIZE, DEFAULT_TICK_TIME, ENABLE_EAGER_ACL_CHECK, firstProcessor, GET_CHILDREN_RESPONSE_CACHE_SIZE, GET_DATA_RESPONSE_CACHE_SIZE, GLOBAL_OUTSTANDING_LIMIT, initialConfig, INT_BUFFER_STARTING_SIZE_BYTES, intBufferStartingSizeBytes, jmxDataTreeBean, jmxServerBean, jvmPauseMonitor, listenBacklog, LOG, maxSessionTimeout, minSessionTimeout, ok, reconfigEnabled, SASL_AUTH_SCHEME, secureServerCnxnFactory, serverCnxnFactory, SESSION_REQUIRE_CLIENT_SASL_AUTH, sessionTracker, SKIP_ACL, SNAP_COUNT, state, tickTime, ZOOKEEPER_DIGEST_ENABLED| Constructor and Description |
|---|
LeaderZooKeeperServer(FileTxnSnapLog logFactory,
QuorumPeer self,
ZKDatabase zkDb) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
checkIfValidGlobalSession(long sess,
int to) |
void |
createSessionTracker() |
int |
getGlobalOutstandingLimit() |
Leader |
getLeader() |
long |
getServerId()
Returns the id of the associated QuorumPeer, which will do for a unique
id of this server.
|
String |
getState() |
protected void |
registerJMX() |
void |
registerJMX(LeaderBean leaderBean,
LocalPeerBean localPeerBean) |
protected void |
registerMetrics() |
protected void |
revalidateSession(ServerCnxn cnxn,
long sessionId,
int sessionTimeout) |
protected void |
setupRequestProcessors() |
void |
shutdown() |
void |
startup() |
void |
submitLearnerRequest(Request request)
Requests coming from the learner should go directly to
PrepRequestProcessor
|
boolean |
touch(long sess,
int to) |
protected void |
unregisterJMX() |
protected void |
unregisterJMX(Leader leader) |
protected void |
unregisterMetrics() |
checkUpgradeSession, dumpConf, dumpMonitorValues, setLocalSessionFlag, setState, startSessionTracker, upgradeauthWriteRequest, canShutdown, checkACL, checkPasswd, checkRequestSizeWhenReceivingMessage, closeSession, closeSession, connThrottle, decInProcess, dumpEphemerals, enqueueRequest, expire, finishSessionInit, getClientPort, getClientPortListenBacklog, getConf, getConnectionDropChance, getDataDirSize, getEphemerals, getGetChildrenResponseCache, getInflight, getInitialConfig, getInProcess, getLargeRequestBytes, getLargeRequestMaxBytes, getLargeRequestThreshold, getLastProcessedZxid, getLogDirSize, getMaxClientCnxnsPerHost, getMaxSessionTimeout, getMinSessionTimeout, getNumAliveConnections, getOutstandingHandshakeNum, getOutstandingRequests, getReadResponseCache, getRequestPathMetricsCollector, getSecureClientPort, getSecureServerCnxnFactory, getServerCnxnFactory, getSessionExpiryMap, getSessionTracker, getSnapCount, getSnapSizeInBytes, getTickTime, getTxnLogElapsedSyncTime, getTxnLogFactory, getZKDatabase, getZooKeeperServerListener, getZxid, incInProcess, isCloseSessionTxnEnabled, isDigestEnabled, isReconfigEnabled, isResponseCachingEnabled, isRunning, killSession, loadData, processConnectRequest, processPacket, processTxn, processTxn, reopenSession, requestFinished, serverStats, setClientPortListenBacklog, setCloseSessionTxnEnabled, setCreateSessionTrackerServerId, setDigestEnabled, setLargeRequestMaxBytes, setLargeRequestThreshold, setMaxSessionTimeout, setMinSessionTimeout, setOwner, setResponseCachingEnabled, setSecureServerCnxnFactory, setServerCnxnFactory, setTickTime, setTxnLogFactory, setZKDatabase, setZxid, shouldThrottle, shutdown, startdata, startJvmPauseMonitor, startRequestThrottler, startServing, startupWithoutServing, submitRequest, submitRequestNow, takeSnapshot, takeSnapshot, truncateLogpublic LeaderZooKeeperServer(FileTxnSnapLog logFactory, QuorumPeer self, ZKDatabase zkDb) throws IOException
IOExceptionpublic Leader getLeader()
protected void setupRequestProcessors()
setupRequestProcessors in class ZooKeeperServerpublic void startup()
startup in class ZooKeeperServerprotected void registerMetrics()
registerMetrics in class QuorumZooKeeperServerprotected void unregisterMetrics()
unregisterMetrics in class QuorumZooKeeperServerpublic void shutdown()
shutdown in class ZooKeeperServerpublic int getGlobalOutstandingLimit()
getGlobalOutstandingLimit in class ZooKeeperServerpublic void createSessionTracker()
createSessionTracker in class ZooKeeperServerpublic boolean touch(long sess,
int to)
public boolean checkIfValidGlobalSession(long sess,
int to)
public void submitLearnerRequest(Request request)
request - protected void registerJMX()
registerJMX in class ZooKeeperServerpublic void registerJMX(LeaderBean leaderBean, LocalPeerBean localPeerBean)
protected void unregisterJMX()
unregisterJMX in class ZooKeeperServerprotected void unregisterJMX(Leader leader)
public String getState()
getState in interface ServerStats.ProvidergetState in class ZooKeeperServerpublic long getServerId()
getServerId in interface SessionTracker.SessionExpirergetServerId in class ZooKeeperServerprotected void revalidateSession(ServerCnxn cnxn, long sessionId, int sessionTimeout) throws IOException
revalidateSession in class ZooKeeperServerIOExceptionCopyright © 2008–2021 The Apache Software Foundation. All rights reserved.