org.apache.synapse.endpoints.dispatch
Class SALSessions

java.lang.Object
  extended by org.apache.synapse.endpoints.dispatch.SALSessions

public class SALSessions
extends Object

Keeps the states of the sessions


Method Summary
 void clearSessions()
          Clear all the expired sessions
 List<Endpoint> getChildEndpoints(SessionInformation information)
          Returns endpoint sequence related to the given session
static SALSessions getInstance()
           
 SessionInformation getSession(String sessionID)
          return the endpoint for the given session.
 void initialize(boolean isClusteringEnable, ConfigurationContext cc)
          Initialize SALSessions instance
 boolean isInitialized()
           
 void registerChildren(Endpoint endpoint, List<Endpoint> endpoints)
          This method only use in a clustered environment.
 void removeSession(String sessionId)
          Removes the endpoint for the given session.
 void reset()
           
 void updateSession(MessageContext synCtx, String sessionID)
          Update or establish a session
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getInstance

public static SALSessions getInstance()

initialize

public void initialize(boolean isClusteringEnable,
                       ConfigurationContext cc)
Initialize SALSessions instance

Parameters:
isClusteringEnable - is this a clustered environment
cc - Axis config context

registerChildren

public void registerChildren(Endpoint endpoint,
                             List<Endpoint> endpoints)
This method only use in a clustered environment.

Parameters:
endpoint - Root endpoint name
endpoints - children

updateSession

public void updateSession(MessageContext synCtx,
                          String sessionID)
Update or establish a session

Parameters:
synCtx - Synapse MessageContext
sessionID - session id

getSession

public SessionInformation getSession(String sessionID)
return the endpoint for the given session. Null will be returned , if there is no endpoint for given session.

Parameters:
sessionID - The session identifier
Returns:
Returns the endpoint for the given session.

getChildEndpoints

public List<Endpoint> getChildEndpoints(SessionInformation information)
Returns endpoint sequence related to the given session

Parameters:
information - Session information
Returns:
endpoint sequence

removeSession

public void removeSession(String sessionId)
Removes the endpoint for the given session.

Parameters:
sessionId - The session identifier

clearSessions

public void clearSessions()
Clear all the expired sessions


isInitialized

public boolean isInitialized()

reset

public void reset()


Copyright © 2005-2012 Apache Software Foundation. All Rights Reserved.