|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface SessionTracker
This is the basic interface that ZooKeeperServer uses to track sessions. The standalone and leader ZooKeeperServer use the same SessionTracker. The FollowerZooKeeperServer uses a SessionTracker which is basically a simple shell to track information to be forwarded to the leader.
Nested Class Summary | |
---|---|
static interface |
SessionTracker.Session
|
static interface |
SessionTracker.SessionExpirer
|
Method Summary | |
---|---|
void |
addSession(long id,
int to)
|
void |
checkSession(long sessionId,
Object owner)
|
long |
createSession(int sessionTimeout)
|
void |
dumpSessions(PrintWriter pwriter)
Text dump of session information, suitable for debugging. |
void |
removeSession(long sessionId)
|
void |
setOwner(long id,
Object owner)
|
void |
setSessionClosing(long sessionId)
Mark that the session is in the process of closing. |
void |
shutdown()
|
boolean |
touchSession(long sessionId,
int sessionTimeout)
|
Method Detail |
---|
long createSession(int sessionTimeout)
void addSession(long id, int to)
boolean touchSession(long sessionId, int sessionTimeout)
sessionId
- sessionTimeout
-
void setSessionClosing(long sessionId)
sessionId
- void shutdown()
void removeSession(long sessionId)
sessionId
- void checkSession(long sessionId, Object owner) throws KeeperException.SessionExpiredException, KeeperException.SessionMovedException
KeeperException.SessionExpiredException
KeeperException.SessionMovedException
void setOwner(long id, Object owner) throws KeeperException.SessionExpiredException
KeeperException.SessionExpiredException
void dumpSessions(PrintWriter pwriter)
pwriter
- the output writer
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |