public class NIOServerCnxn extends ServerCnxn
ServerCnxn.CloseRequestException, ServerCnxn.EndOfStreamException
Watcher.Event
authInfo, cmd2String, confCmd, consCmd, count, crstCmd, dumpCmd, enviCmd, established, getTraceMaskCmd, isroCmd, lastCxid, lastLatency, lastOp, lastResponseTime, lastZxid, maxLatency, me, minLatency, mntrCmd, packetsReceived, packetsSent, ruokCmd, setTraceMaskCmd, srstCmd, srvrCmd, statCmd, totalLatency, wchcCmd, wchpCmd, wchsCmd, zooKeeperSaslServer
Constructor and Description |
---|
NIOServerCnxn(ZooKeeperServer zk,
java.nio.channels.SocketChannel sock,
java.nio.channels.SelectionKey sk,
NIOServerCnxnFactory factory) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
void |
disableRecv() |
void |
enableRecv() |
int |
getInterestOps() |
long |
getOutstandingRequests()
The number of requests that have been submitted but not yet
responded to.
|
java.net.InetSocketAddress |
getRemoteSocketAddress() |
long |
getSessionId() |
int |
getSessionTimeout() |
protected void |
incrOutstandingRequests(RequestHeader h) |
void |
process(WatchedEvent event) |
void |
sendBuffer(java.nio.ByteBuffer bb) |
void |
sendCloseSession() |
void |
sendResponse(ReplyHeader h,
org.apache.jute.Record r,
java.lang.String tag) |
protected ServerStats |
serverStats() |
void |
setSessionId(long sessionId) |
void |
setSessionTimeout(int sessionTimeout) |
java.lang.String |
toString()
Prints detailed stats information for the connection.
|
addAuthInfo, dumpConnectionInfo, getAuthInfo, getAvgLatency, getEstablished, getLastCxid, getLastLatency, getLastOperation, getLastResponseTime, getLastZxid, getMaxLatency, getMinLatency, getPacketsReceived, getPacketsSent, incrPacketsReceived, incrPacketsSent, packetReceived, packetSent, removeAuthInfo, resetStats, updateStatsForResponse
public NIOServerCnxn(ZooKeeperServer zk, java.nio.channels.SocketChannel sock, java.nio.channels.SelectionKey sk, NIOServerCnxnFactory factory) throws java.io.IOException
java.io.IOException
public void sendCloseSession()
public void sendBuffer(java.nio.ByteBuffer bb)
protected void incrOutstandingRequests(RequestHeader h)
incrOutstandingRequests
in class ServerCnxn
public void disableRecv()
public void enableRecv()
public long getOutstandingRequests()
getOutstandingRequests
in class ServerCnxn
public int getSessionTimeout()
public java.lang.String toString()
ServerCnxn
toString
in class ServerCnxn
for brief stats
public void close()
public void sendResponse(ReplyHeader h, org.apache.jute.Record r, java.lang.String tag)
sendResponse
in class ServerCnxn
public void process(WatchedEvent event)
process
in interface Watcher
process
in class ServerCnxn
public long getSessionId()
public void setSessionId(long sessionId)
public void setSessionTimeout(int sessionTimeout)
public int getInterestOps()
getInterestOps
in class ServerCnxn
public java.net.InetSocketAddress getRemoteSocketAddress()
getRemoteSocketAddress
in class ServerCnxn
protected ServerStats serverStats()
serverStats
in class ServerCnxn
Copyright © 2016 The Apache Software Foundation