|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface SessionService
The session service deals with managing sessions; this involves creating sessions, closing sessions, terminating sessions, and updating session state.
A session has a timestamp, information about the principal owning the session, and a "state" indicating whether it is actively in use, in use but passivated, or has been rendered invalid by being closed or terminated, or by expiring.
Note that this service does not deal with authentication explicitly, but may use a membership service provider to authenticate some requests.
| Field Summary | |
|---|---|
static long |
DEFAULT_MAX_SESSIONS
|
static long |
DEFAULT_SESSION_EXPIRATION
|
static java.lang.String |
MAX_SESSIONS
|
static java.lang.String |
NAME
|
static java.lang.String |
SESSION_EXPIRATION
|
| Method Summary | |
|---|---|
void |
closeSession(java.lang.String sessionID)
Closes the specified session. |
SessionMetadata |
createSession(java.lang.String userName,
Credentials credentials,
java.lang.String applicationName,
java.util.Properties properties,
boolean admin,
boolean authenticate)
Create a session for the given user authenticating against the given Credentials. |
SessionMetadata |
getActiveSession(java.lang.String sessionID)
|
java.util.Collection<SessionMetadata> |
getActiveSessions()
Get the collection of active user sessions on the system. |
int |
getActiveSessionsCount()
Get the number of active user sessions on the system. |
java.util.Collection<SessionMetadata> |
getSessionsLoggedInToVDB(java.lang.String VDBName,
int VDBVersion)
Get all MetaMatrixSessionIDs that are in the ACTIVE state
and currently logged in to a VDB. |
void |
pingServer(java.lang.String sessionID)
Periodically called by the client to indicate the client is still alive. |
void |
setDqp(org.teiid.dqp.internal.process.DQPCore dqp)
|
boolean |
terminateSession(java.lang.String terminatedSessionID,
java.lang.String adminSessionID)
Terminates the specified session. |
SessionMetadata |
validateSession(java.lang.String sessionID)
This method is intended to verify that the session is valid, and, if need be, set the session in an active state, ready to be used. |
| Field Detail |
|---|
static final java.lang.String NAME
static final long DEFAULT_MAX_SESSIONS
static final long DEFAULT_SESSION_EXPIRATION
static final java.lang.String MAX_SESSIONS
static final java.lang.String SESSION_EXPIRATION
| Method Detail |
|---|
SessionMetadata createSession(java.lang.String userName,
Credentials credentials,
java.lang.String applicationName,
java.util.Properties properties,
boolean admin,
boolean authenticate)
throws javax.security.auth.login.LoginException,
SessionServiceException
Credentials.
javax.security.auth.login.LoginException
SessionServiceException
void closeSession(java.lang.String sessionID)
throws InvalidSessionException
sessionID - The MetaMatrixSessionID identifying user's session
to be closed
InvalidSessionException - If sessionID identifies an invalid
session
SessionServiceException
boolean terminateSession(java.lang.String terminatedSessionID,
java.lang.String adminSessionID)
terminatedSessionID - The MetaMatrixSessionID identifying user's session
to be terminatedadminSessionID - The session id identifying session of administrator
InvalidSessionException - If terminatedSessionID identifies an invalid
session
does not have authority to terminate the terminatedSessionID session
SessionServiceException
java.util.Collection<SessionMetadata> getActiveSessions()
throws SessionServiceException
SessionServiceException
int getActiveSessionsCount()
throws SessionServiceException
SessionServiceException
SessionMetadata validateSession(java.lang.String sessionID)
throws InvalidSessionException,
SessionServiceException
sessionID - MetaMatrixSessionID representing the session
InvalidSessionException - If sessionID identifies an invalid
session
SessionServiceException
java.util.Collection<SessionMetadata> getSessionsLoggedInToVDB(java.lang.String VDBName,
int VDBVersion)
throws SessionServiceException
MetaMatrixSessionIDs that are in the ACTIVE state
and currently logged in to a VDB.
VDBName - The name of the VDB.VDBVersion - The version of the VDB.
SessionServiceException - when transaction with database fails or unexpected exception happens
void pingServer(java.lang.String sessionID)
throws InvalidSessionException
sessionID - - identifies the client
InvalidSessionExceptionSessionMetadata getActiveSession(java.lang.String sessionID)
void setDqp(org.teiid.dqp.internal.process.DQPCore dqp)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||