public class SplitHttpSessionModel extends TraditionalHttpSessionModel
Modifier and Type | Class and Description |
---|---|
static class |
SplitHttpSessionModel.ElasticKey<P,Integer>
ElasticKey, used by to store segments of a large value that exceeds
the flash journal size limit.
|
Base.LoggingWriter, Base.StackFrame
Modifier and Type | Field and Description |
---|---|
protected static Map<String,Integer> |
s_mapElastic
The map of cache and its max value size if using elastic data.
|
static ValueExtractor |
SESSION_ID_EXTRACTOR
ValueExtractor that can be used to extract the session ID from an
external attribute key.
|
CTX_OPTIMIZE_MODIFIED_SESSIONS, MAGIC_V350, STRING_ARRAY
Constructor and Description |
---|
SplitHttpSessionModel()
Default constructor for deserialization.
|
SplitHttpSessionModel(SplitHttpSessionCollection collection,
javax.servlet.http.HttpSession session,
String sId)
Session creation constructor.
|
Modifier and Type | Method and Description |
---|---|
protected void |
flush()
Flush the changes to this model to whatever data structure (for
example, a cache) that is responsible for managing the model's data.
|
protected NamedCache |
getExternalCache()
Obtain the cache that holds split-out (external) attribute values.
|
int |
getMinExternalAttributeSize()
Determine the minimum size of an attribute such that it is considered
"large" and will be stored in a separate "external" or "overflow"
cache.
|
protected Map<Object,Set<SplitHttpSessionModel.ElasticKey>> |
getMultiExternalMap()
Obtain the caches that hold segments of large (external) attribute value.
|
protected SplitHttpSessionCollection |
getSplitHttpSessionCollection()
Get the SplitHttpSessionCollection that contains this model.
|
protected AttributeHolder |
instantiateAttributeHolder()
Factory method: Instantiate an AttributeHolder for deserialization
purposes.
|
protected AttributeHolder |
instantiateAttributeHolder(String sName,
Object oValue)
Factory method: Instantiate an AttributeHolder to manage the passed
value.
|
protected void |
remapExternalAttributes(String sIdNew)
Copy all attributes which are stored in an external cache so that the
attribute key reflects the new session id.
|
protected void |
removeExternalAttribute(Object oKey)
Removes an external attribute from the external cache.
|
protected void |
removeExternalAttributes()
Helper method used to forcefully remove all external attributes from
the external attribute cache.
|
protected void |
setCollection(AbstractHttpSessionCollection collection)
After deserialization, the collection needs to be configured.
|
protected void |
setExternalBinary(Object oKey,
Binary binValue)
Adds this binary value to the temporary map for flushing.
|
String |
toString()
Returns a string representation of the object.
|
protected void |
unbind()
Unbind session attributes.
|
activate, addEnteredThread, bind, checkActive, checkUsable, checkValid, discard, enter, exit, extractAttributeName, extractAttributeNames, getActualAttributeMap, getAttribute, getAttributeMap, getAttributeNameArray, getCollection, getCreationTime, getDescription, getEnteredThreads, getHttpSession, getId, getLastAccessedTime, getLastFlushedTime, getLocalAttributeMap, getMaxInactiveInterval, getNewId, getReferenceCount, getThreadOwner, getVersion, isActivatableAttributes, isActive, isExpired, isExpiredInternal, isImmutable, isLastAccessTimeFlushRequired, isLocal, isModified, isNew, isOwnedByThisThread, isUsable, isValid, logAttributeSerializationFailure, obtainThreadOwnership, passivate, qualifyAttributeName, readAttributes, readExternal, readExternal, releaseThreadOwnership, removeAttribute, removeEnteredThread, resetReferenceCount, sessionReturned, setActivatableAttributes, setAttribute, setHttpSession, setId, setLastAccessedTime, setLastFlushedTime, setMaxInactiveInterval, setModified, setNewId, setValid, setVersion, touch, unbind, writeAttributes, writeExternal, writeExternal
azzert, azzert, azzert, azzertFailed, breakLines, breakLines, capitalize, checkNotEmpty, checkNotNull, checkRange, computeSafeWaitTime, decimalValue, dup, dup, ensureBigDecimal, ensureClassLoader, ensureRuntimeException, ensureRuntimeException, equals, equalsDeep, err, err, err, err, err, escape, formatDateTime, getCallerStackFrame, getCommonMonitor, getCommonMonitor, getCommonMonitor, getContextClassLoader, getContextClassLoader, getDeepMessage, getErr, getLastSafeTimeMillis, getLog, getMaxDecDigits, getMaxHexDigits, getOriginalException, getOut, getProcessRandom, getRandom, getRandomBinary, getRandomBinary, getRandomString, getSafeTimeMillis, getStackFrame, getStackFrames, getStackTrace, getStackTrace, getStackTrace, getThreadFactory, getTimeZone, getUpTimeMillis, hashCode, hexValue, indentString, indentString, isDecimal, isHex, isLogEcho, isOctal, log, log, log, log, log, makeInteger, makeLong, makeThread, mergeArray, mergeBooleanArray, mergeByteArray, mergeCharArray, mergeDoubleArray, mergeFloatArray, mergeIntArray, mergeLongArray, mod, mod, octalValue, out, out, out, out, out, pad, parseBandwidth, parseBandwidth, parseDelimitedString, parseHex, parseHex, parseMemorySize, parseMemorySize, parsePercentage, parseTime, parseTime, parseTimeNanos, parseTimeNanos, printStackTrace, randomize, randomize, randomize, randomize, read, read, read, read, read, read, read, replace, setErr, setLog, setLogEcho, setOut, sleep, toBandwidthString, toBandwidthString, toCharEscape, toCrc, toCrc, toCrc, toCrc, toCrc, toDecString, toDelimitedString, toDelimitedString, toDelimitedString, toDelimitedString, toHex, toHex, toHexDump, toHexEscape, toHexEscape, toHexEscape, toHexEscape, toHexString, toMemorySizeString, toMemorySizeString, toQuotedCharEscape, toQuotedStringEscape, toSqlString, toString, toString, toStringEscape, toUnicodeEscape, trace, trace, trace, trace, trace, trace, trace, trace, trace, truncateString, truncateString, wait
public static ValueExtractor SESSION_ID_EXTRACTOR
public SplitHttpSessionModel()
public SplitHttpSessionModel(SplitHttpSessionCollection collection, javax.servlet.http.HttpSession session, String sId)
collection
- the collection that manages this modelsession
- the session that delegates to this modelsId
- the session IDpublic String toString()
toString
in class TraditionalHttpSessionModel
protected void unbind()
This method may only be called by a thread that owns this model. See
AbstractHttpSessionCollection.obtainThreadOwnership(java.lang.String)
.
unbind
in class AbstractHttpSessionModel
protected void flush()
This method may only be called by a thread that owns this model. See
AbstractHttpSessionCollection.obtainThreadOwnership(java.lang.String)
.
flush
in class AbstractHttpSessionModel
protected void setCollection(AbstractHttpSessionCollection collection)
setCollection
in class AbstractHttpSessionModel
collection
- the AbstractHttpSessionCollection that this model belongs toprotected SplitHttpSessionCollection getSplitHttpSessionCollection()
protected void removeExternalAttributes()
protected void setExternalBinary(Object oKey, Binary binValue)
oKey
- The attribute namebinValue
- The binary valueprotected void removeExternalAttribute(Object oKey)
oKey
- the keypublic int getMinExternalAttributeSize()
protected NamedCache getExternalCache()
protected Map<Object,Set<SplitHttpSessionModel.ElasticKey>> getMultiExternalMap()
protected void remapExternalAttributes(String sIdNew)
sIdNew
- the new session idprotected AttributeHolder instantiateAttributeHolder()
instantiateAttributeHolder
in class TraditionalHttpSessionModel
protected AttributeHolder instantiateAttributeHolder(String sName, Object oValue)
instantiateAttributeHolder
in class TraditionalHttpSessionModel
sName
- the attribute nameoValue
- a non-null Object value