|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sun.xml.ws.runtime.util.SessionManager
public abstract class SessionManager
The SessionManager
is used to obtain session information
This can be implemented using persisitent storage mechanisms or using transient storage
Even if it is implemented using persistent storage the implementation should take care
of backing by a cache which will avoid the overhead of serialization and database
operations
Additonally the SessionManager
is responsible for managing the lifecycle
events for the sessions. It exposes methods to create and terminate the session
Periodically the SessionManager
will check for sessions who have been inactive for
a predefined amount of time and then will terminate those sessions
Constructor Summary | |
---|---|
SessionManager()
|
Method Summary | |
---|---|
abstract void |
addSecurityContext(java.lang.String key,
com.sun.xml.ws.security.IssuedTokenContext itctx)
Add the SecurityContext with key in local cache |
abstract Session |
createSession(java.lang.String key)
Creates a Session with the given key, using an instance of java.util.Hashtable |
abstract Session |
createSession(java.lang.String key,
java.lang.Class clasz)
Creates a Session with the given key, using a new instance of the specified Class as a holder for user-defined data. |
abstract Session |
createSession(java.lang.String key,
java.lang.Object obj)
Creates a Session with the given key, using the specified Object as a holder for user-defined data. |
abstract java.util.Set<java.lang.String> |
getKeys()
Returns the Set of valid Session keys. |
abstract com.sun.xml.ws.security.IssuedTokenContext |
getSecurityContext(java.lang.String key,
boolean checkExpiry)
Return the valid SecurityContext for matching key |
abstract Session |
getSession(java.lang.String key)
Returns an existing session identified by the Key else null |
static SessionManager |
getSessionManager()
Returns the single instance of SessionManager Use the usual services mechanism to find implementing class. |
abstract void |
saveSession(java.lang.String key)
Saves the state of the Session with the given key. |
abstract void |
terminateSession(java.lang.String key)
Removed the Session with the given key. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SessionManager()
Method Detail |
---|
public abstract Session getSession(java.lang.String key)
key
- The Session key.public abstract java.util.Set<java.lang.String> getKeys()
public abstract void terminateSession(java.lang.String key)
key
- The key of the Session to be removed.public abstract Session createSession(java.lang.String key, java.lang.Class clasz)
key
- The Session key to be used.public abstract Session createSession(java.lang.String key, java.lang.Object obj)
key
- The Session key to be used.obj
- The object to use as a holder for user data in the session.public abstract Session createSession(java.lang.String key)
key
- The Session key to be used.public abstract void saveSession(java.lang.String key)
key
- The key of the session to be savedpublic abstract com.sun.xml.ws.security.IssuedTokenContext getSecurityContext(java.lang.String key, boolean checkExpiry)
key
- The key of the security context to be lookedexpiryCheck
- indicates whether to check the token expiry or not,
As in case of renew we don't need to check token expirypublic abstract void addSecurityContext(java.lang.String key, com.sun.xml.ws.security.IssuedTokenContext itctx)
key
- The key of the security context to be storeditctx
- The IssuedTokenContext to be storedpublic static SessionManager getSessionManager()
com.sun.xml.ws.runtime.util.SessionManager
by default.
manager
field.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |