Skip navigation links

Oracle® Coherence Java API Reference
Release 3.7.0.0

E18683-01


com.tangosol.coherence.servlet
Interface HttpSessionCollection.SessionDistributionController

All Known Implementing Classes:
AbstractHttpSessionCollection.DistributedController, AbstractHttpSessionCollection.HybridController, AbstractHttpSessionCollection.LocalController
Enclosing interface:
HttpSessionCollection

Deprecated. In releases following 3.6 customization will be declarative.

public static interface HttpSessionCollection.SessionDistributionController

An optional interface to override the default distribution of session objects in the cluster, allowing the sessions to remain "local" to the originating application until a later point in the life of the session, that point determined by the implementation of this interface.

Further, once a session is distributed, the distribution of its attributes can be controlled in the same manner, specifying that some attributes remain local and others are distributed.

This interface exists primarily to assist in the conversion from non-distributed to distributed systems, particularly when concerns exist about the cost of distribution of all sessions and all attributes.

Since:
Coherence 2.4

Method Summary
 void init(HttpSessionCollection collection)
          Deprecated. Initialize the session distribution controller, so that it has the necessary context with which to make decisions regarding when to distribute sessions and their attributes.
 boolean isSessionAttributeDistributed(HttpSessionModel model, java.lang.String sName)
          Deprecated. Determine if the specified attribute of the HttpSession associated with the passed session model should be distributed.
 boolean isSessionDistributed(HttpSessionModel model)
          Deprecated. Determine if the HttpSession associated with the passed session model should be distributed.

 

Method Detail

init

void init(HttpSessionCollection collection)
Deprecated. 
Initialize the session distribution controller, so that it has the necessary context with which to make decisions regarding when to distribute sessions and their attributes.
Parameters:
collection - the HttpSessionCollection object for which the distribution controller is working

isSessionDistributed

boolean isSessionDistributed(HttpSessionModel model)
Deprecated. 
Determine if the HttpSession associated with the passed session model should be distributed. This method will only be called for sessions that are not already distributed.
Parameters:
model - the model for the HttpSession to evaluate for distribution
Returns:
true if the passed session model should be distributed

isSessionAttributeDistributed

boolean isSessionAttributeDistributed(HttpSessionModel model,
                                      java.lang.String sName)
Deprecated. 
Determine if the specified attribute of the HttpSession associated with the passed session model should be distributed. This method will only be called for sessions that are distributed, and only for attributes that are not already distributed. Further, it may only be called when an attribute is added or when its value is modified. The value itself is not passed for performance reasons; if necessary, the implementation can obtain the value from the model, but it is suggested that the implementation use the name to make the determination if possible, and only failing that obtain and evaluate the attribute value.
Parameters:
model - the model for the HttpSession being evaluated
sName - the name of the session attribute to evaluate for distribution
Returns:
true if the specified attribute for the passed session model should be distributed

Skip navigation links

Oracle® Coherence Java API Reference
Release 3.7.0.0

E18683-01


Copyright © 2000, 2011, Oracle and/or its affiliates. All rights reserved.