public class SessionManager extends Object
Session
.Constructor and Description |
---|
SessionManager(DefaultContext defaultContext) |
Modifier and Type | Method and Description |
---|---|
void |
closeSession(SessionHandle sessionId) |
int |
currentSessionCount() |
int |
getOperationCount(SessionHandle sessionHandle) |
Session |
getSession(SessionHandle sessionHandle) |
Session |
openSession(SessionEnvironment environment)
Register the session into the
SessionManager . |
void |
start() |
void |
stop() |
public SessionManager(DefaultContext defaultContext)
public void start()
public void stop()
public Session getSession(SessionHandle sessionHandle) throws SqlGatewayException
SqlGatewayException
public Session openSession(SessionEnvironment environment) throws SqlGatewayException
SessionManager
.
Use synchronized to keep the checkSessionCount and build the Session are atomic.
SqlGatewayException
public void closeSession(SessionHandle sessionId) throws SqlGatewayException
SqlGatewayException
@VisibleForTesting public int currentSessionCount()
@VisibleForTesting public int getOperationCount(SessionHandle sessionHandle)
Copyright © 2014–2024 The Apache Software Foundation. All rights reserved.