Package org.apache.zookeeper.server
Interface ConnectionMXBean
-
- All Known Implementing Classes:
ConnectionBean
public interface ConnectionMXBeanThis MBean represents a client connection.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description longgetAvgLatency()Average latency in msjava.lang.String[]getEphemeralNodes()java.lang.StringgetLastCxid()Last cxid of this connectionlonggetLastLatency()Latency of last response to client on this connection in msjava.lang.StringgetLastOperation()Last operation performed by this connectionjava.lang.StringgetLastResponseTime()Last time server sent a response to client on this connectionjava.lang.StringgetLastZxid()Last zxid of this connectionlonggetMaxLatency()Max latency in mslonggetMinLatency()Min latency in mslonggetOutstandingRequests()longgetPacketsReceived()longgetPacketsSent()java.lang.StringgetSessionId()intgetSessionTimeout()java.lang.StringgetSourceIP()java.lang.StringgetStartedTime()voidresetCounters()Reset countersvoidterminateConnection()Terminate thei client connection.voidterminateSession()Terminate this client session.
-
-
-
Method Detail
-
getSourceIP
java.lang.String getSourceIP()
- Returns:
- source (client) IP address
-
getSessionId
java.lang.String getSessionId()
- Returns:
- client's session id
-
getStartedTime
java.lang.String getStartedTime()
- Returns:
- time the connection was started
-
getEphemeralNodes
java.lang.String[] getEphemeralNodes()
- Returns:
- number of ephemeral nodes owned by this connection
-
getPacketsReceived
long getPacketsReceived()
- Returns:
- packets received from this client
-
getPacketsSent
long getPacketsSent()
- Returns:
- number of packets sent to this client
-
getOutstandingRequests
long getOutstandingRequests()
- Returns:
- number of requets being processed
-
getSessionTimeout
int getSessionTimeout()
- Returns:
- session timeout in ms
-
terminateSession
void terminateSession()
Terminate this client session. The client will reconnect with a different session id.
-
terminateConnection
void terminateConnection()
Terminate thei client connection. The client will immediately attempt to reconnect with the same session id.
-
getMinLatency
long getMinLatency()
Min latency in ms- Since:
- 3.3.0
-
getAvgLatency
long getAvgLatency()
Average latency in ms- Since:
- 3.3.0
-
getMaxLatency
long getMaxLatency()
Max latency in ms- Since:
- 3.3.0
-
getLastOperation
java.lang.String getLastOperation()
Last operation performed by this connection- Since:
- 3.3.0
-
getLastCxid
java.lang.String getLastCxid()
Last cxid of this connection- Since:
- 3.3.0
-
getLastZxid
java.lang.String getLastZxid()
Last zxid of this connection- Since:
- 3.3.0
-
getLastResponseTime
java.lang.String getLastResponseTime()
Last time server sent a response to client on this connection- Since:
- 3.3.0
-
getLastLatency
long getLastLatency()
Latency of last response to client on this connection in ms- Since:
- 3.3.0
-
resetCounters
void resetCounters()
Reset counters- Since:
- 3.3.0
-
-