|
||||||||||
PREV CLASS NEXT CLASS (src) | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Interface for services providing clustered state session availability
HASessionStateImpl
(src) Nested Class Summary | |
static interface |
HASessionState.HASessionStateListener (src)
Information that can be used to clean a cache for example. |
Method Summary | |
void |
createSession(java.lang.String appName,
java.lang.Object keyId)
Share a new session state in the sub-partition of this cluster |
HAPartition (src) |
getCurrentHAPartition()
|
java.lang.String |
getNodeName()
Return the name of this node as used in the computations |
PackagedSession (src) |
getState(java.lang.String appName,
java.lang.Object keyId)
Get a particular state |
PackagedSession (src) |
getStateWithOwnership(java.lang.String appName,
java.lang.Object keyId)
Get a state and, if it is not already the case, takes its ownership (a state is always owned by a node) |
void |
init()
|
void |
removeSession(java.lang.String appName,
java.lang.Object keyId)
Remove a session from the sub-partition |
void |
setState(java.lang.String appName,
java.lang.Object keyId,
byte[] state)
Modifies a state already shared |
void |
start()
|
void |
subscribe(java.lang.String appName,
HASessionState.HASessionStateListener (src) listener)
Subscribe to receive notifications when objects gets modified on another node. |
void |
takeOwnership(java.lang.String appName,
java.lang.Object keyId)
Take ownership of a state. |
void |
unsubscribe(java.lang.String appName,
HASessionState.HASessionStateListener (src) listener)
|
Method Detail |
public void init() throws java.lang.Exception
java.lang.Exception
public void start() throws java.lang.Exception
java.lang.Exception
public void subscribe(java.lang.String appName, HASessionState.HASessionStateListener (src) listener)
public void unsubscribe(java.lang.String appName, HASessionState.HASessionStateListener (src) listener)
public HAPartition (src) getCurrentHAPartition()
public java.lang.String getNodeName()
public void createSession(java.lang.String appName, java.lang.Object keyId)
appName
- Application name for which is state is sharedkeyId
- Key identifier of the statepublic void setState(java.lang.String appName, java.lang.Object keyId, byte[] state) throws java.rmi.RemoteException
appName
- Application name hosting this statekeyId
- Key identifier of the state to modifystate
- New state
java.rmi.RemoteException
public PackagedSession (src) getState(java.lang.String appName, java.lang.Object keyId)
appName
- Application hosting the statekeyId
- Key identifier of the state
public PackagedSession (src) getStateWithOwnership(java.lang.String appName, java.lang.Object keyId) throws java.rmi.RemoteException
appName
- Application hosting the statekeyId
- Key identifier of the state
java.rmi.RemoteException
- Thrown if an exception occurs while getting the ownership of the statepublic void takeOwnership(java.lang.String appName, java.lang.Object keyId) throws java.rmi.RemoteException
appName
- Application hosting the statekeyId
- Key identifier of the state
java.rmi.RemoteException
- Trown if a communication exception occurs while asking other node to get the ownershippublic void removeSession(java.lang.String appName, java.lang.Object keyId)
appName
- Application hosting the statekeyId
- Key identifier of the state
|
||||||||||
PREV CLASS NEXT CLASS (src) | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |