public abstract class XSSessionManager
extends java.lang.Object
Session, inlcude session life cycle (createSession, attachSession, detachSessiona and destroySession), session attribute (cookie, inactivity timeout) and session namespace. It also provides functions to initialize the middle-tier cache and manage it. The following code snippet provides a typical use of this class:
XSSessionManager manager = XSSessionManager.getSessionManager(cacheConn,
30, 2048000);
Session lws = manager.createSession(lwsConn, user, cookie);
manager.attachSession(lws_conn, lws, ...);
boolean ret = XSAccessController.checkPrivilege(lws, "UPDATE");
manager.detachSession(lws);
manager.destroySession(lws);
Most of the methods in this class are not static, and very security sensitive. The caller has to get hold of an object to call the methods. The object is highly protected. The only way to get the object is to call getSessionManager with followings:
- XSSecurityPermission ("initSecurityManager") to be granted to the caller's code
- Dispatcher's DB connection or Datasource
In the integration case, we expect only trusted layer (OPSS) can initialize and get hold of the the XSSessionManager object. Application code should not be able to get hold of the object and further invoke most of the methods.| Constructor and Description |
|---|
XSSessionManager() |
| Modifier and Type | Method and Description |
|---|---|
abstract void |
abortSession(Session session)
Detaches this session.
|
abstract void |
assignUser(Session session, ExternalUser targetUser, java.util.Collection<java.lang.String> enabledDynamicRoles, java.util.Collection<java.lang.String> disabledDynamicRoles, java.util.Collection<ExternalRole> externalRoles, java.util.Collection<NamespaceValue> namespaceValues, java.sql.Timestamp authenticationTime)
Assigns an external user to the session that was previously created for anonymous user.
|
abstract void |
assignUser(Session session, java.lang.String targetUser, java.util.Collection<java.lang.String> enabledDynamicRoles, java.util.Collection<java.lang.String> disabledDynamicRoles, java.util.Collection<NamespaceValue> namespaceValues, java.sql.Timestamp authenticationTime)
Assigns an XS user to the session that was previously created for anonymous user.
|
abstract void |
attachSession(java.sql.Connection conn, Session session, java.util.Collection<java.lang.String> enabledDynamicRoles, java.util.Collection<java.lang.String> disabledDynamicRoles, java.util.Collection<ExternalRole> externalRoles, java.util.Collection<NamespaceValue> namespaceValues, java.sql.Timestamp authenticationTime)
Attaches the JDBC connection to the specified XS user's session.
|
abstract void |
attachSession(java.sql.Connection conn, Session session, java.util.Collection<java.lang.String> enabledDynamicRoles, java.util.Collection<java.lang.String> disabledDynamicRoles, java.util.Collection<NamespaceValue> namespaceValues, java.sql.Timestamp authenticationTime)
Attaches the JDBC connection to the specified XS user's session.
|
abstract Session |
attachSessionByCookie(java.sql.Connection conn, java.lang.String cookie, java.util.Collection<java.lang.String> enabledDynamicRoles, java.util.Collection<java.lang.String> disabledDynamicRoles, java.util.Collection<ExternalRole> externalRoles, java.util.Collection<NamespaceValue> namespaceValues, java.sql.Timestamp authenticationTime)
Attaches the corresponding session for a specified cookie and returns the Session object.
|
abstract Session |
attachSessionByID(java.sql.Connection conn, java.lang.String id, java.util.Collection<java.lang.String> enabledDynamicRoles, java.util.Collection<java.lang.String> disabledDynamicRoles, java.util.Collection<ExternalRole> externalRoles, java.util.Collection<NamespaceValue> namespaceValues, java.sql.Timestamp authenticationTime)
Attaches the corresponding session for a specified ID and returns the Session object.
|
abstract void |
clearCache()
Explicitly clears the shared cache from the middle tier.
|
abstract Session |
createAnonymousSession(java.sql.Connection conn, java.lang.String cookie, java.util.Collection<NamespaceValue> namespaceValues)
Creates an anonymous
Session for XS user (to be assigned to) on the server as well as its corresponding middle-tier representation. |
abstract Session |
createAnonymousSessionTrusted(java.sql.Connection conn, java.lang.String cookie, java.util.Collection<NamespaceValue> namespaceValues)
Creates an anonymous
Session in trusted mode on the server for external user (to be assigned to) as well as its corresponding middle-tier representation. |
abstract SessionNamespaceAttribute |
createAttribute(SessionNamespace sessionNS, java.lang.String name, java.lang.String value, java.util.List<SessionNamespace.ATTR_EVENT_TYPE> event)
Creates a new attribute in the namespace with the specified name, value, and event.
|
abstract SessionNamespace |
createNamespace(Session session, java.lang.String name)
Creates a new namespace for the given session.
|
abstract Session |
createSession(java.sql.Connection conn, ExternalUser externalUser, java.lang.String cookie, java.util.Collection<NamespaceValue> namespaceValues)
Creates a
Session object for specified external user on the server as well as its corresponding middle-tier representation. |
abstract Session |
createSession(java.sql.Connection conn, java.lang.String user, java.lang.String cookie, java.util.Collection<NamespaceValue> namespaceValues)
Creates a
Session object on the server as well as its corresponding midtier representation. |
abstract Session |
createSessionTrusted(java.sql.Connection conn, ExternalUser externalUser, java.lang.String cookie, java.util.Collection<NamespaceValue> namespaceValues)
Creates a
Session object for specified external user in trusted mode on the server as well as its corresponding middle-tier representation. |
abstract void |
deleteAttribute(SessionNamespace sessionNS, java.lang.String name)
Deletes the specified attribute The dispatcher needs to have the privilege to delete the given attribute
|
abstract void |
deleteNamespace(Session session, java.lang.String namespace)
Removes a namespace from the session.
|
abstract void |
destroySession(java.sql.Connection conn, Session session)
Destroys the XS session.
|
abstract void |
detachSession(Session session)
Detaches this session.
|
abstract int |
getCacheMaxIdleTime()
Returns the maximum number of minutes for which the cache can remain without any activity
|
abstract long |
getCacheMaxSize()
Returns the maximum cache size, in bytes.
|
abstract float |
getHighWaterMark()
Gets the high watermark for the cache.
|
abstract float |
getLowWaterMark()
Gets the low watermark for the cache.
|
abstract int |
getPrivateCacheMaxEntries()
Returns the maximum number of entries that the ACL evaluation result can be cached in the session.
|
static XSSessionManager |
getSessionManager(java.sql.Connection conn, int cacheMaxIdleTime, int cacheMaxsize)
Initializes an
XSSessionManager using a dedicated connections. |
static XSSessionManager |
getSessionManager(javax.sql.DataSource datasource, int cacheMaxIdleTime, int cacheMaxsize)
Initializes an
XSSessionManager using connections from the connection pool. |
abstract SessionNamespaceAttribute |
resetAttribute(SessionNamespace sessionNS, java.lang.String name)
Resets the specified attribute in the namespace to its default value.
|
abstract void |
saveSession(Session session)
Saves the specified session leaving it attached.
|
abstract SessionNamespaceAttribute |
setAttribute(SessionNamespace sessionNS, java.lang.String name, java.lang.String value)
Sets the attribute for a session namespace with the specified name and value The dispatcher needs to have the privilege to set the attribute on the given namespace
|
abstract void |
setCacheMaxIdleTime(int minutes)
Sets the maximum number of minutes for which the cache can remain without any activity.
|
abstract void |
setCacheMaxSize(long megaBytes)
Sets the size of the cache on the middle tier, in bytes.
|
abstract void |
setCookie(Session session, java.lang.String cookie)
Sets the cookie for the session
|
abstract void |
setInactivityTimeout(Session session, int minutes)
Sets the inactivity timeout for the session in minutes.
|
abstract void |
setPrivateCacheMaxEntries(int maxEntries)
Sets the maximum number of entries that the ACL evaluation result can be cached in the session.
|
abstract void |
setWaterMark(float low, float high)
Sets the high and low watermarks for the cache.
|
public abstract Session createSession(java.sql.Connection conn, java.lang.String user, java.lang.String cookie, java.util.Collection<NamespaceValue> namespaceValues) throws InvalidXSUserException, AccessDeniedException, java.sql.SQLException, XSException, InvalidXSNamespaceException
Session object on the server as well as its corresponding midtier representation. It also creates or changes the Namespace specified in the Session. The cookie can be used to identify the newly created XS user session in future calls, until the cookie value is changed or the session is destroyed. By default, the session is created in secure mode.conn - the JDBC connection for server roundtripuser - the XS user associated with the Sessioncookie - used to identify the sessionnamespaceValues - the namespace with attributes The user must have the bindNamespace privilege.Session objectAccessDeniedException - if the current user does not have the privilege to create this sessionjava.sql.SQLException - if a JDBC exception happensInvalidXSUserException - if an invalid XS user is specifiedXSException - if a generic error is detectedInvalidXSNamespaceException - if an invalid namespace is specifiedSession, SessionNamespacepublic abstract Session createAnonymousSession(java.sql.Connection conn, java.lang.String cookie, java.util.Collection<NamespaceValue> namespaceValues) throws InvalidXSUserException, AccessDeniedException, java.sql.SQLException, XSException, InvalidXSNamespaceException
Session for XS user (to be assigned to) on the server as well as its corresponding middle-tier representation. It also creates or changes the Namespace specified in the Session. The user for this session is a seeded anonymous user. The cookie can be used to identify the newly created XS user session in future calls, until the cookie value is changed or the session is destroyed. It is possible to assign a specific user to take over this session that will keep some of the state of the session.
By default, the session is created in secure mode.
conn - the JDBC connection for server roundtripcookie - used to identify the sessionnamespaceValues - a list of namespaces with attributesAccessDeniedException - if the current user does not have the privilege to create this sessionjava.sql.SQLException - if a JDBC exception happensInvalidXSUserException - if an invalid XS user is specifiedXSException - if a generic error is detectedInvalidXSNamespaceException - if an invalid namespace is specifiedSession, SessionNamespacepublic abstract Session createAnonymousSessionTrusted(java.sql.Connection conn, java.lang.String cookie, java.util.Collection<NamespaceValue> namespaceValues) throws InvalidXSUserException, AccessDeniedException, java.sql.SQLException, XSException, InvalidXSNamespaceException
Session in trusted mode on the server for external user (to be assigned to) as well as its corresponding middle-tier representation. It also creates or changes the Namespace specified in the Session . The session is going to be assigned to an extenal user, which has no footprint at Database, so no database role is enabled in the session. The user for this session is a seeded anonymous user. The cookie can be used to identify the newly created session in future calls, until the cookie value is changed or the session is destroyed. It is possible to assign a specific external user to take over this session that will keep some of the state of the session.conn - the JDBC connection for server roundtripcookie - used to identify the sessionnamespaceValues - a list of namespaces with attributesAccessDeniedException - if the current user does not have the privilege to create this sessionjava.sql.SQLException - if a JDBC exception happensInvalidXSUserException - if an invalid XS user is specifiedXSException - if a generic error is detectedInvalidXSNamespaceException - if an invalid namespace is specifiedSession, SessionNamespacepublic abstract void saveSession(Session session) throws java.sql.SQLException, NotAttachedException, XSException
session, - a Session objectjava.sql.SQLExceptionNotAttachedExceptionXSExceptionpublic abstract Session createSessionTrusted(java.sql.Connection conn, ExternalUser externalUser, java.lang.String cookie, java.util.Collection<NamespaceValue> namespaceValues) throws InvalidXSUserException, AccessDeniedException, java.sql.SQLException, XSException, InvalidXSNamespaceException
Session object for specified external user in trusted mode on the server as well as its corresponding middle-tier representation. It also creates or changes the Namespace specified in the Session. The cookie can be used to identify the newly session in future calls, until the cookie value is changed or the session is destroyed.conn - the JDBC connection for server roundtripexternalUser - the external user associated with the Sessioncookie - used to identify the sessionnamespaceValues - the namespace with attributesSession objectAccessDeniedException - if the current user does not have the privilege to create this sessionjava.sql.SQLException - if a JDBC exception happensInvalidXSUserException - if an invalid XS user is specifiedXSException - if a generic error is detectedInvalidXSNamespaceException - if an invalid namespace is specifiedSession, SessionNamespacepublic abstract Session createSession(java.sql.Connection conn, ExternalUser externalUser, java.lang.String cookie, java.util.Collection<NamespaceValue> namespaceValues) throws InvalidXSUserException, AccessDeniedException, java.sql.SQLException, XSException, InvalidXSNamespaceException
Session object for specified external user on the server as well as its corresponding middle-tier representation. It also creates or changes the Namespace specified for the Session.
The cookie can be used to identify the newly created XS user session in future calls, until the cookie value is changed or the session is destroyed. By default, the session is in secure mode
conn - the JDBC connection for server roundtripexternalUser - the external user associated with the Sessioncookie - used to identify the sessionnamespaceValues - the namespace with attributesSession objectAccessDeniedException - if the current user does not have the privilege to create this sessionjava.sql.SQLException - if a JDBC exception happensInvalidXSUserException - if an invalid XS user is specifiedXSException - if a generic error is detectedInvalidXSNamespaceException - if an invalid namespace is specifiedSession, SessionNamespacepublic abstract Session attachSessionByCookie(java.sql.Connection conn, java.lang.String cookie, java.util.Collection<java.lang.String> enabledDynamicRoles, java.util.Collection<java.lang.String> disabledDynamicRoles, java.util.Collection<ExternalRole> externalRoles, java.util.Collection<NamespaceValue> namespaceValues, java.sql.Timestamp authenticationTime) throws java.sql.SQLException, AccessDeniedException, InvalidSessionException, XSException, InvalidXSNamespaceException
conn - the JDBC connection for server roundtripcookie - the cookie stringenabledDynamicRoles - the enabled dynamic roles listdisabledDynamicRoles - the disabled dyamic roles listexternalRoles - the external roles listnamespaceValues - the namespaces with attributes.authenticationTime - the authentication timeSession objectAccessDeniedException - if the current user does not have the privilege to create this sessionjava.sql.SQLException - if a JDBC exception happensInvalidXSUserException - if an invalid XS user is specifiedXSException - if a generic error is detectedInvalidXSNamespaceException - if an invalid namespace is specifiedInvalidSessionExceptionpublic abstract Session attachSessionByID(java.sql.Connection conn, java.lang.String id, java.util.Collection<java.lang.String> enabledDynamicRoles, java.util.Collection<java.lang.String> disabledDynamicRoles, java.util.Collection<ExternalRole> externalRoles, java.util.Collection<NamespaceValue> namespaceValues, java.sql.Timestamp authenticationTime) throws java.sql.SQLException, AccessDeniedException, InvalidSessionException, XSException, InvalidXSNamespaceException
conn - the JDBC connection for server roundtripid - the session ID of the sessionenabledDynamicRoles - the enabled dynamic roles listdisabledDynamicRoles - the disabled dyamic roles listexternalRoles - the external roles listnamespaceValues - the namespaces with attributes.authenticationTime - the authentication timeSession objectAccessDeniedException - if the current user does not have the privilege to create this sessionjava.sql.SQLException - if a JDBC exception happensInvalidXSUserException - if an invalid XS user is specifiedXSException - if a generic error is detectedInvalidXSNamespaceException - if an invalid namespace is specifiedInvalidSessionExceptionpublic abstract void attachSession(java.sql.Connection conn,
Session session,
java.util.Collection<java.lang.String> enabledDynamicRoles,
java.util.Collection<java.lang.String> disabledDynamicRoles,
java.util.Collection<ExternalRole> externalRoles,
java.util.Collection<NamespaceValue> namespaceValues,
java.sql.Timestamp authenticationTime)
throws java.sql.SQLException,
AccessDeniedException,
InvalidSessionException,
XSException,
InvalidXSNamespaceException
conn - database connection to be used to attach to the sessionsession - the session object that needs to be attachedenabledDynamicRoles - a collection of dynamic role names to be enableddisabledDynamicRoles - a collection of dynamic role names to be disabledexternalRoles - a collection of ExternalRoles to be enablednamespaceValues - a list of NamespaceAttributeValue objects to be createdauthenticationTime - the authenticateion timeAccessDeniedException - the current user does not have the privilege to attach to this sessionXSException - a generic error is detectedjava.sql.SQLException - a JDBC exception is thrownInvalidSessionException - an attempt is made to reference an invalid sessionInvalidXSNamespaceException - if an invalid namespace is specifiedSession, oracle.security.xs.NamespaceAttributeValuepublic abstract void attachSession(java.sql.Connection conn,
Session session,
java.util.Collection<java.lang.String> enabledDynamicRoles,
java.util.Collection<java.lang.String> disabledDynamicRoles,
java.util.Collection<NamespaceValue> namespaceValues,
java.sql.Timestamp authenticationTime)
throws java.sql.SQLException,
AccessDeniedException,
InvalidSessionException,
XSException,
InvalidXSNamespaceException
conn - database connection to be used to attach to the sessionsession - the session object that needs to be attachedenabledDynamicRoles - a collection of dynamic role names to be enableddisabledDynamicRoles - a collection of dynamic role names to be disablednamespaceValues - a list of NamespaceAttributeValue objects to be createdauthenticationTime - the authenticateion timeAccessDeniedException - the current user does not have the privilege to attach to this sessionXSException - a generic error is detectedjava.sql.SQLException - a JDBC exception is thrownInvalidSessionException - an attempt is made to reference an invalid sessionInvalidXSNamespaceException - if an invalid namespace is specifiedSession, oracle.security.xs.NamespaceAttributeValuepublic abstract void detachSession(Session session) throws java.sql.SQLException, NotAttachedException, XSException
java.sql.SQLException - a JDBC exception is thrownXSException - a generic error is detectedNotAttachedException - session not attachedpublic abstract void abortSession(Session session) throws java.sql.SQLException, NotAttachedException, XSException
java.sql.SQLException - a JDBC exception is thrownXSException - a generic error is detectedNotAttachedException - session not attachedpublic abstract void destroySession(java.sql.Connection conn,
Session session)
throws java.sql.SQLException,
XSException,
AccessDeniedException,
InvalidSessionException
conn - the JDBC Connection used to make a roundtrip operation to the server and destroy the sessionAccessDeniedException - the current user does not have the privilege to destroyXSException - a generic error is detectedjava.sql.SQLException - a JDBC exception is thrownInvalidSessionException - an attempt is made to reference an invalid sessionpublic abstract void assignUser(Session session, java.lang.String targetUser, java.util.Collection<java.lang.String> enabledDynamicRoles, java.util.Collection<java.lang.String> disabledDynamicRoles, java.util.Collection<NamespaceValue> namespaceValues, java.sql.Timestamp authenticationTime) throws java.sql.SQLException, AccessDeniedException, InvalidSessionException, XSException, InvalidXSNamespaceException
session - Session obejct to assign user ontargetUser - a user initialized based on authenticationenabledDynamicRoles - a list of dynamic role names to be enableddisabledDynamicRoles - a list of dynamic role names to be disablednamespaceValues - a list of NamespaceValue objects to be created.authenticationTime - a timestamp indicated if the user authenticatedAccessDeniedException - the current user does not have the privilege to switchuserXSException - a generic error is detectedjava.sql.SQLException - a JDBC exception is thrownInvalidSessionException - an attempt is made to reference an invalid sessionInvalidXSUserException - an invalid XS user is specifiedNotAttachedException - session not attachedInvalidXSNamespaceException - if an invalid namespace is specifiedpublic abstract void assignUser(Session session, ExternalUser targetUser, java.util.Collection<java.lang.String> enabledDynamicRoles, java.util.Collection<java.lang.String> disabledDynamicRoles, java.util.Collection<ExternalRole> externalRoles, java.util.Collection<NamespaceValue> namespaceValues, java.sql.Timestamp authenticationTime) throws java.sql.SQLException, AccessDeniedException, InvalidSessionException, XSException, InvalidXSNamespaceException
session - Session obejct to assign user ontargetUser - a User object initialized based on authenticationenabledDynamicRoles - a list of dynamic role names to be enableddisabledDynamicRoles - a list of dynamic role names to be disabledexternalRoles - a list of external roles to be grantednamespaceValues - a list of NamespaceAttributeValue objects to be created.authenticationTime - a timestamp indicated if the user authenticatedAccessDeniedException - the current user does not have the privilege to switchuserXSException - a generic error is detectedjava.sql.SQLException - a JDBC exception is thrownInvalidSessionException - an attempt is made to reference an invalid sessionInvalidXSUserException - an invalid XS user is specifiedNotAttachedException - session not attachedInvalidXSNamespaceException - if an invalid namespace is specifiedpublic abstract void clearCache()
throws java.security.AccessControlException,
XSSessionManagerException
java.security.AccessControlException - if security manager is enabled and clearCache XSSecurityPermission is not grantedXSSecurityManagerException - XSSecurityManager is not initializedXSSessionManagerExceptionpublic static XSSessionManager getSessionManager(javax.sql.DataSource datasource, int cacheMaxIdleTime, int cacheMaxsize) throws XSException, java.security.NoSuchAlgorithmException, java.security.InvalidAlgorithmParameterException, java.security.spec.InvalidKeySpecException, java.security.InvalidKeyException, java.sql.SQLException
XSSessionManager using connections from the connection pool. By default, the initialized XSSessionManager will sign the request. So the given connection pool user will be used to authorize the session operations. The caller of this method needs to have initSecurityManager XSSecurityPermission if security manager is enabled.datasource - the connection pool DateSource for the database connectioncacheMaxIdleTime - maximum amount of time that the cache persists, in minutes, before synchronizing with the servercacheMaxsize - maximum allowable size, in bytes, of the ACL or SecurityClass cacheXSException - a generic error is detectedjava.security.NoSuchAlgorithmException - a particular cryptographic algorithm is requested but is not available in the environmentjava.security.InvalidAlgorithmParameterException - invalid or inappropriate algorithm parametersjava.security.spec.InvalidKeySpecException - invalid key specificationsjava.security.InvalidKeyException - invalid Keysjava.sql.SQLException - a problem in the SQLpublic static XSSessionManager getSessionManager(java.sql.Connection conn, int cacheMaxIdleTime, int cacheMaxsize) throws XSException, java.security.NoSuchAlgorithmException, java.security.InvalidAlgorithmParameterException, java.security.spec.InvalidKeySpecException, java.security.InvalidKeyException, java.sql.SQLException
XSSessionManager using a dedicated connections. By default, the initialized XSSessionManager will sign the request. So the given connection will be used to authorize the session operations. The caller of this method needs to have initSecurityManager XSSecurityPermission if security manager is enabled.conn - decicated JDBC connectioncacheMaxIdleTime - maximum amount of time that the cache persists, in minutes, before synchronizing with the servercacheMaxsize - maximum allowable size, in bytes, of the ACL or SecurityClass cacheXSException - a generic error is detectedjava.security.NoSuchAlgorithmException - a particular cryptographic algorithm is requested but is not available in the environmentjava.security.InvalidAlgorithmParameterException - invalid or inappropriate algorithm parametersjava.security.spec.InvalidKeySpecException - invalid key specificationsjava.security.InvalidKeyException - invalid Keysjava.sql.SQLException - a problem in the SQLpublic abstract int getCacheMaxIdleTime()
throws XSSessionManagerException
XSSecurityManagerException - XSSecurityManager is not initializedXSSessionManagerExceptionpublic abstract void setCacheMaxIdleTime(int minutes)
throws java.security.AccessControlException,
XSSessionManagerException
XSSecurityPermission if security manager is enabled.minutes - the maximum number of minutes for which the cache can remain without any activityjava.security.AccessControlException - if missing required permissionXSSecurityManagerException - if XSSecurityManager is not initializedXSSessionManagerExceptionpublic abstract long getCacheMaxSize()
throws XSSessionManagerException
XSSecurityManagerException - if XSSecurityManager is not initializedXSSessionManagerExceptionpublic abstract void setCacheMaxSize(long megaBytes)
throws java.security.AccessControlException,
XSSessionManagerException
XSSecurityPermission if security manager is enabled.megaBytes - integer value representing cache in bytesjava.security.AccessControlException - if missing required permissionXSSecurityManagerException - if XSSecurityManager is not initialized.XSSessionManagerExceptionpublic abstract float getHighWaterMark()
throws XSSessionManagerException
XSSecurityManagerException - if XSSecurityManager is not initializedXSSessionManagerExceptionpublic abstract float getLowWaterMark()
throws XSSessionManagerException
XSSecurityManagerException - if XSSecurityManager is not initializedXSSessionManagerExceptionpublic abstract void setWaterMark(float low,
float high)
throws java.security.AccessControlException,
XSSessionManagerException
XSSecurityPermission if security manager is enabled.low - low watermark valuehigh - high watermark valuejava.security.AccessControlException - if missing required permissionXSSecurityManagerException - if XSSecurityManager is not initializedXSSessionManagerExceptionpublic abstract int getPrivateCacheMaxEntries()
public abstract void setPrivateCacheMaxEntries(int maxEntries)
throws java.security.AccessControlException,
XSSessionManagerException
XSSecurityPermission if security manager is enabled.maxEntries - number of cache entriesjava.security.AccessControlExceptionXSSessionManagerExceptionpublic abstract void setCookie(Session session, java.lang.String cookie) throws XSException
session - the session to be setcookie - value of the cookieXSException - a generic error is detectedpublic abstract void setInactivityTimeout(Session session, int minutes) throws XSException
session - the session to be setminutes - number in minutesXSException - a generic error is detectedpublic abstract SessionNamespace createNamespace(Session session, java.lang.String name) throws java.sql.SQLException, AccessDeniedException, XSException, InvalidXSNamespaceException, InvalidSessionException, NotAttachedException
session - the given sessionname - the name of the session namespace.SessionNamespace that is createdAccessDeniedException - the dispatcher does not have the privilege to create the namespaceXSException - a generic error is detectedjava.sql.SQLException - a JDBC exception is thrownInvalidXSNamespaceException - namespace already existsInvalidSessionException - an attempt is made to reference an invalid sessionNotAttachedException - session not attachedpublic abstract void deleteNamespace(Session session, java.lang.String namespace) throws java.sql.SQLException, AccessDeniedException, XSException, InvalidXSNamespaceException, InvalidSessionException, NotAttachedException
session - the given sessionnamespace - the namespace to be removedAccessDeniedException - the dispatcher does not have the privilege to delete this namespacejava.sql.SQLException - a JDBC exception is thrownInvalidXSNamespaceException - namespace is invalidInvalidSessionException - attempted to reference an invalid sessionNotAttachedException - session not attachedXSException - a generic error is detectedpublic abstract SessionNamespaceAttribute createAttribute(SessionNamespace sessionNS, java.lang.String name, java.lang.String value, java.util.List<SessionNamespace.ATTR_EVENT_TYPE> event) throws java.sql.SQLException, SessionNamespaceException, AccessDeniedException, XSException, InvalidXSAttributeException, NotAttachedException
sessionNS - the given SessionNamespacename - name of the attributevalue - value of the attributeevent - event registration of the attributejava.sql.SQLException - when a JDBC exception is thrownAccessDeniedException - when the dispatcher does not have the privilegeXSException - when a generic error is detectedSessionNamespaceException - when the attibute name is invalidInvalidXSAttributeException - when the attribute value is invalidNotAttachedException - when the session is not attachedpublic abstract void deleteAttribute(SessionNamespace sessionNS, java.lang.String name) throws java.sql.SQLException, AccessDeniedException, XSException, InvalidXSAttributeException, NotAttachedException
sessionNS - the given SessionNamespacename - name of the attributejava.sql.SQLException - when a JDBC exception is thrownAccessDeniedException - when the dispatcher user does not have the privilege to delete the attributeXSException - when a generic error is detectedInvalidXSAttributeException - when the attribute is invalidNotAttachedException - when the session is not attachedpublic abstract SessionNamespaceAttribute resetAttribute(SessionNamespace sessionNS, java.lang.String name) throws java.sql.SQLException, AccessDeniedException, XSException, InvalidXSAttributeException, NotAttachedException
sessionNS - the given SessionNamespacename - name of the attributejava.sql.SQLException - when a JDBC exception is thrownAccessDeniedException - when the current user does not have the privilege to reset the attributeXSException - when a generic error is detectedInvalidXSAttributeException - when the attribute is invalidNotAttachedException - when the session is not attachedpublic abstract SessionNamespaceAttribute setAttribute(SessionNamespace sessionNS, java.lang.String name, java.lang.String value) throws java.sql.SQLException, SessionNamespaceException, AccessDeniedException, XSException, InvalidXSAttributeException, NotAttachedException
sessionNS - the given SessionNamespacename - name of the attributevalue - value of the attributejava.sql.SQLException - when a JDBC exception is thrownAccessDeniedException - when the dispatcher does not have the privilege to set the attribute on the namespace/attributeXSException - when a generic error is detectedSessionNamespaceException - when the namespace is invalidInvalidXSAttributeException - when the attribute is invalidNotAttachedException - when the session is not attached