Package org.apache.zookeeper.server
Class ZooKeeperServerBean
- java.lang.Object
 - 
- org.apache.zookeeper.server.ZooKeeperServerBean
 
 
- 
- All Implemented Interfaces:
 ZKMBeanInfo,ZooKeeperServerMXBean
- Direct Known Subclasses:
 FollowerBean,LeaderBean,ObserverBean,ReadOnlyBean
public class ZooKeeperServerBean extends Object implements ZooKeeperServerMXBean, ZKMBeanInfo
This class implements the ZooKeeper server MBean interface. 
- 
- 
Field Summary
Fields Modifier and Type Field Description protected ZooKeeperServerzks 
- 
Constructor Summary
Constructors Constructor Description ZooKeeperServerBean(ZooKeeperServer zks) 
- 
Method Summary
 
 - 
 
- 
- 
Field Detail
- 
zks
protected final ZooKeeperServer zks
 
 - 
 
- 
Constructor Detail
- 
ZooKeeperServerBean
public ZooKeeperServerBean(ZooKeeperServer zks)
 
 - 
 
- 
Method Detail
- 
getClientPort
public String getClientPort()
- Specified by:
 getClientPortin interfaceZooKeeperServerMXBean- Returns:
 - the server socket port number
 
 
- 
getName
public String getName()
- Specified by:
 getNamein interfaceZKMBeanInfo- Returns:
 - a string identifying the MBean
 
 
- 
isHidden
public boolean isHidden()
Description copied from interface:ZKMBeanInfoIf isHidden returns true, the MBean won't be registered with MBean server, and thus won't be available for management tools. Used for grouping MBeans.- Specified by:
 isHiddenin interfaceZKMBeanInfo- Returns:
 - true if the MBean is hidden.
 
 
- 
getStartTime
public String getStartTime()
- Specified by:
 getStartTimein interfaceZooKeeperServerMXBean- Returns:
 - time the server was started
 
 
- 
getVersion
public String getVersion()
- Specified by:
 getVersionin interfaceZooKeeperServerMXBean- Returns:
 - the zookeeper server version
 
 
- 
getAvgRequestLatency
public double getAvgRequestLatency()
- Specified by:
 getAvgRequestLatencyin interfaceZooKeeperServerMXBean- Returns:
 - average request latency in ms
 
 
- 
getMaxRequestLatency
public long getMaxRequestLatency()
- Specified by:
 getMaxRequestLatencyin interfaceZooKeeperServerMXBean- Returns:
 - max request latency in ms
 
 
- 
getMinRequestLatency
public long getMinRequestLatency()
- Specified by:
 getMinRequestLatencyin interfaceZooKeeperServerMXBean- Returns:
 - min request latency in ms
 
 
- 
getOutstandingRequests
public long getOutstandingRequests()
- Specified by:
 getOutstandingRequestsin interfaceZooKeeperServerMXBean- Returns:
 - number of outstanding requests.
 
 
- 
getTickTime
public int getTickTime()
Description copied from interface:ZooKeeperServerMXBeanCurrent TickTime of server in milliseconds- Specified by:
 getTickTimein interfaceZooKeeperServerMXBean
 
- 
setTickTime
public void setTickTime(int tickTime)
Description copied from interface:ZooKeeperServerMXBeanSet TickTime of server in milliseconds- Specified by:
 setTickTimein interfaceZooKeeperServerMXBean
 
- 
getMaxClientCnxnsPerHost
public int getMaxClientCnxnsPerHost()
Description copied from interface:ZooKeeperServerMXBeanCurrent maxClientCnxns allowed from a particular host- Specified by:
 getMaxClientCnxnsPerHostin interfaceZooKeeperServerMXBean
 
- 
setMaxClientCnxnsPerHost
public void setMaxClientCnxnsPerHost(int max)
Description copied from interface:ZooKeeperServerMXBeanSet maxClientCnxns allowed from a particular host- Specified by:
 setMaxClientCnxnsPerHostin interfaceZooKeeperServerMXBean
 
- 
getMinSessionTimeout
public int getMinSessionTimeout()
Description copied from interface:ZooKeeperServerMXBeanCurrent minSessionTimeout of the server in milliseconds- Specified by:
 getMinSessionTimeoutin interfaceZooKeeperServerMXBean
 
- 
setMinSessionTimeout
public void setMinSessionTimeout(int min)
Description copied from interface:ZooKeeperServerMXBeanSet minSessionTimeout of server in milliseconds- Specified by:
 setMinSessionTimeoutin interfaceZooKeeperServerMXBean
 
- 
getMaxSessionTimeout
public int getMaxSessionTimeout()
Description copied from interface:ZooKeeperServerMXBeanCurrent maxSessionTimeout of the server in milliseconds- Specified by:
 getMaxSessionTimeoutin interfaceZooKeeperServerMXBean
 
- 
setMaxSessionTimeout
public void setMaxSessionTimeout(int max)
Description copied from interface:ZooKeeperServerMXBeanSet maxSessionTimeout of server in milliseconds- Specified by:
 setMaxSessionTimeoutin interfaceZooKeeperServerMXBean
 
- 
getDataDirSize
public long getDataDirSize()
- Specified by:
 getDataDirSizein interfaceZooKeeperServerMXBean- Returns:
 - estimated size of data directory in bytes
 
 
- 
getLogDirSize
public long getLogDirSize()
- Specified by:
 getLogDirSizein interfaceZooKeeperServerMXBean- Returns:
 - estimated size of log directory in bytes
 
 
- 
getPacketsReceived
public long getPacketsReceived()
- Specified by:
 getPacketsReceivedin interfaceZooKeeperServerMXBean- Returns:
 - number of packets received so far
 
 
- 
getPacketsSent
public long getPacketsSent()
- Specified by:
 getPacketsSentin interfaceZooKeeperServerMXBean- Returns:
 - number of packets sent so far
 
 
- 
getFsyncThresholdExceedCount
public long getFsyncThresholdExceedCount()
- Specified by:
 getFsyncThresholdExceedCountin interfaceZooKeeperServerMXBean- Returns:
 - number of fsync threshold exceeds so far
 
 
- 
getAuthFailedCount
public long getAuthFailedCount()
- Specified by:
 getAuthFailedCountin interfaceZooKeeperServerMXBean- Returns:
 - number of AuthFailedCount so far
 
 
- 
getNonMTLSRemoteConnCount
public long getNonMTLSRemoteConnCount()
- Specified by:
 getNonMTLSRemoteConnCountin interfaceZooKeeperServerMXBean- Returns:
 - number of NonMTLSRemoteConnCount so far
 
 
- 
getNonMTLSLocalConnCount
public long getNonMTLSLocalConnCount()
- Specified by:
 getNonMTLSLocalConnCountin interfaceZooKeeperServerMXBean- Returns:
 - number of NonMTLSLocalConnCount so far
 
 
- 
resetLatency
public void resetLatency()
Description copied from interface:ZooKeeperServerMXBeanReset min/avg/max latency statistics- Specified by:
 resetLatencyin interfaceZooKeeperServerMXBean
 
- 
resetMaxLatency
public void resetMaxLatency()
Description copied from interface:ZooKeeperServerMXBeanReset max latency statistics only.- Specified by:
 resetMaxLatencyin interfaceZooKeeperServerMXBean
 
- 
resetFsyncThresholdExceedCount
public void resetFsyncThresholdExceedCount()
Description copied from interface:ZooKeeperServerMXBeanReset Fsync Threshold Exceed Count statistics only.- Specified by:
 resetFsyncThresholdExceedCountin interfaceZooKeeperServerMXBean
 
- 
resetAuthFailedCount
public void resetAuthFailedCount()
Description copied from interface:ZooKeeperServerMXBeanReset AuthFailedCount statistics only.- Specified by:
 resetAuthFailedCountin interfaceZooKeeperServerMXBean
 
- 
resetNonMTLSConnCount
public void resetNonMTLSConnCount()
Description copied from interface:ZooKeeperServerMXBeanReset NonMTLS(Local+Remote)ConnCount statistics only.- Specified by:
 resetNonMTLSConnCountin interfaceZooKeeperServerMXBean
 
- 
resetStatistics
public void resetStatistics()
Description copied from interface:ZooKeeperServerMXBeanReset packet and latency statistics- Specified by:
 resetStatisticsin interfaceZooKeeperServerMXBean
 
- 
getNumAliveConnections
public long getNumAliveConnections()
- Specified by:
 getNumAliveConnectionsin interfaceZooKeeperServerMXBean- Returns:
 - number of alive client connections
 
 
- 
getSecureClientPort
public String getSecureClientPort()
- Specified by:
 getSecureClientPortin interfaceZooKeeperServerMXBean- Returns:
 - secure client port
 
 
- 
getSecureClientAddress
public String getSecureClientAddress()
- Specified by:
 getSecureClientAddressin interfaceZooKeeperServerMXBean- Returns:
 - secure client address
 
 
- 
getTxnLogElapsedSyncTime
public long getTxnLogElapsedSyncTime()
Description copied from interface:ZooKeeperServerMXBeanReturns the elapsed sync of time of transaction log in milliseconds.- Specified by:
 getTxnLogElapsedSyncTimein interfaceZooKeeperServerMXBean
 
- 
getJuteMaxBufferSize
public int getJuteMaxBufferSize()
- Specified by:
 getJuteMaxBufferSizein interfaceZooKeeperServerMXBean- Returns:
 - Returns the value of the following config setting: jute.maxbuffer
 
 
- 
getLastClientResponseSize
public int getLastClientResponseSize()
- Specified by:
 getLastClientResponseSizein interfaceZooKeeperServerMXBean- Returns:
 - size of latest generated client response
 
 
- 
getMinClientResponseSize
public int getMinClientResponseSize()
- Specified by:
 getMinClientResponseSizein interfaceZooKeeperServerMXBean- Returns:
 - size of smallest generated client response
 
 
- 
getMaxClientResponseSize
public int getMaxClientResponseSize()
- Specified by:
 getMaxClientResponseSizein interfaceZooKeeperServerMXBean- Returns:
 - size of largest generated client response
 
 
- 
getResponseCachingEnabled
public boolean getResponseCachingEnabled()
- Specified by:
 getResponseCachingEnabledin interfaceZooKeeperServerMXBean
 
- 
setResponseCachingEnabled
public void setResponseCachingEnabled(boolean isEnabled)
- Specified by:
 setResponseCachingEnabledin interfaceZooKeeperServerMXBean
 
- 
getConnectionMaxTokens
public int getConnectionMaxTokens()
- Specified by:
 getConnectionMaxTokensin interfaceZooKeeperServerMXBean
 
- 
setConnectionMaxTokens
public void setConnectionMaxTokens(int val)
- Specified by:
 setConnectionMaxTokensin interfaceZooKeeperServerMXBean
 
- 
getConnectionTokenFillTime
public int getConnectionTokenFillTime()
- Specified by:
 getConnectionTokenFillTimein interfaceZooKeeperServerMXBean
 
- 
setConnectionTokenFillTime
public void setConnectionTokenFillTime(int val)
- Specified by:
 setConnectionTokenFillTimein interfaceZooKeeperServerMXBean
 
- 
getConnectionTokenFillCount
public int getConnectionTokenFillCount()
- Specified by:
 getConnectionTokenFillCountin interfaceZooKeeperServerMXBean
 
- 
setConnectionTokenFillCount
public void setConnectionTokenFillCount(int val)
- Specified by:
 setConnectionTokenFillCountin interfaceZooKeeperServerMXBean
 
- 
getConnectionFreezeTime
public int getConnectionFreezeTime()
- Specified by:
 getConnectionFreezeTimein interfaceZooKeeperServerMXBean
 
- 
setConnectionFreezeTime
public void setConnectionFreezeTime(int val)
- Specified by:
 setConnectionFreezeTimein interfaceZooKeeperServerMXBean
 
- 
getConnectionDropIncrease
public double getConnectionDropIncrease()
- Specified by:
 getConnectionDropIncreasein interfaceZooKeeperServerMXBean
 
- 
setConnectionDropIncrease
public void setConnectionDropIncrease(double val)
- Specified by:
 setConnectionDropIncreasein interfaceZooKeeperServerMXBean
 
- 
getConnectionDropDecrease
public double getConnectionDropDecrease()
- Specified by:
 getConnectionDropDecreasein interfaceZooKeeperServerMXBean
 
- 
setConnectionDropDecrease
public void setConnectionDropDecrease(double val)
- Specified by:
 setConnectionDropDecreasein interfaceZooKeeperServerMXBean
 
- 
getConnectionDecreaseRatio
public double getConnectionDecreaseRatio()
- Specified by:
 getConnectionDecreaseRatioin interfaceZooKeeperServerMXBean
 
- 
setConnectionDecreaseRatio
public void setConnectionDecreaseRatio(double val)
- Specified by:
 setConnectionDecreaseRatioin interfaceZooKeeperServerMXBean
 
- 
getCommitProcMaxReadBatchSize
public int getCommitProcMaxReadBatchSize()
- Specified by:
 getCommitProcMaxReadBatchSizein interfaceZooKeeperServerMXBean
 
- 
setCommitProcMaxReadBatchSize
public void setCommitProcMaxReadBatchSize(int size)
- Specified by:
 setCommitProcMaxReadBatchSizein interfaceZooKeeperServerMXBean
 
- 
getCommitProcMaxCommitBatchSize
public int getCommitProcMaxCommitBatchSize()
- Specified by:
 getCommitProcMaxCommitBatchSizein interfaceZooKeeperServerMXBean
 
- 
setCommitProcMaxCommitBatchSize
public void setCommitProcMaxCommitBatchSize(int size)
- Specified by:
 setCommitProcMaxCommitBatchSizein interfaceZooKeeperServerMXBean
 
- 
getFlushDelay
public long getFlushDelay()
- Specified by:
 getFlushDelayin interfaceZooKeeperServerMXBean
 
- 
setFlushDelay
public void setFlushDelay(long delay)
- Specified by:
 setFlushDelayin interfaceZooKeeperServerMXBean
 
- 
getThrottledOpWaitTime
public int getThrottledOpWaitTime()
- Specified by:
 getThrottledOpWaitTimein interfaceZooKeeperServerMXBean
 
- 
setThrottledOpWaitTime
public void setThrottledOpWaitTime(int val)
- Specified by:
 setThrottledOpWaitTimein interfaceZooKeeperServerMXBean
 
- 
getRequestThrottleLimit
public int getRequestThrottleLimit()
- Specified by:
 getRequestThrottleLimitin interfaceZooKeeperServerMXBean
 
- 
setRequestThrottleLimit
public void setRequestThrottleLimit(int requests)
- Specified by:
 setRequestThrottleLimitin interfaceZooKeeperServerMXBean
 
- 
getRequestThrottleStallTime
public int getRequestThrottleStallTime()
- Specified by:
 getRequestThrottleStallTimein interfaceZooKeeperServerMXBean
 
- 
setRequestThrottleStallTime
public void setRequestThrottleStallTime(int time)
- Specified by:
 setRequestThrottleStallTimein interfaceZooKeeperServerMXBean
 
- 
getRequestThrottleDropStale
public boolean getRequestThrottleDropStale()
- Specified by:
 getRequestThrottleDropStalein interfaceZooKeeperServerMXBean
 
- 
setRequestThrottleDropStale
public void setRequestThrottleDropStale(boolean drop)
- Specified by:
 setRequestThrottleDropStalein interfaceZooKeeperServerMXBean
 
- 
getMaxWriteQueuePollTime
public long getMaxWriteQueuePollTime()
- Specified by:
 getMaxWriteQueuePollTimein interfaceZooKeeperServerMXBean
 
- 
setMaxWriteQueuePollTime
public void setMaxWriteQueuePollTime(long delay)
- Specified by:
 setMaxWriteQueuePollTimein interfaceZooKeeperServerMXBean
 
- 
getRequestStaleLatencyCheck
public boolean getRequestStaleLatencyCheck()
- Specified by:
 getRequestStaleLatencyCheckin interfaceZooKeeperServerMXBean
 
- 
setRequestStaleLatencyCheck
public void setRequestStaleLatencyCheck(boolean check)
- Specified by:
 setRequestStaleLatencyCheckin interfaceZooKeeperServerMXBean
 
- 
getMaxBatchSize
public int getMaxBatchSize()
- Specified by:
 getMaxBatchSizein interfaceZooKeeperServerMXBean
 
- 
setMaxBatchSize
public void setMaxBatchSize(int size)
- Specified by:
 setMaxBatchSizein interfaceZooKeeperServerMXBean
 
- 
getRequestStaleConnectionCheck
public boolean getRequestStaleConnectionCheck()
- Specified by:
 getRequestStaleConnectionCheckin interfaceZooKeeperServerMXBean
 
- 
setRequestStaleConnectionCheck
public void setRequestStaleConnectionCheck(boolean check)
- Specified by:
 setRequestStaleConnectionCheckin interfaceZooKeeperServerMXBean
 
- 
getLargeRequestMaxBytes
public int getLargeRequestMaxBytes()
- Specified by:
 getLargeRequestMaxBytesin interfaceZooKeeperServerMXBean
 
- 
setLargeRequestMaxBytes
public void setLargeRequestMaxBytes(int bytes)
- Specified by:
 setLargeRequestMaxBytesin interfaceZooKeeperServerMXBean
 
- 
getLargeRequestThreshold
public int getLargeRequestThreshold()
- Specified by:
 getLargeRequestThresholdin interfaceZooKeeperServerMXBean
 
- 
setLargeRequestThreshold
public void setLargeRequestThreshold(int threshold)
- Specified by:
 setLargeRequestThresholdin interfaceZooKeeperServerMXBean
 
- 
getMaxCnxns
public int getMaxCnxns()
- Specified by:
 getMaxCnxnsin interfaceZooKeeperServerMXBean- Returns:
 - Current maxCnxns allowed to a single ZooKeeper server
 
 
 - 
 
 -