Package com.tangosol.net.cache
Class AbstractKeyBundler
java.lang.Object
com.tangosol.util.Base
com.tangosol.net.cache.AbstractBundler
com.tangosol.net.cache.AbstractKeyBundler
- Direct Known Subclasses:
BundlingNamedCache.GetBundler,BundlingNamedCache.RemoveBundler
An abstract key-based bundler serves as a base for NamedCache get() and
remove() operation bundling as well as the CacheStore load() and erase()
operation bundling.
- Since:
- Coherence 3.3
- Author:
- gg 2007.01.28
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected classBundle represents a unit of optimized execution.Nested classes/interfaces inherited from class com.tangosol.net.cache.AbstractBundler
AbstractBundler.StatisticsNested classes/interfaces inherited from class com.tangosol.util.Base
Base.LoggingWriter -
Field Summary
Fields inherited from class com.tangosol.net.cache.AbstractBundler
ADJUSTMENT_FREQUENCY, m_countThreads, m_dPreviousSizeThreshold, m_listBundle -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract Mapbundle(Collection colKeys) The bundle operation to be performed against a collected set of keys by the concrete AbstractKeyBundler implementations.protected AbstractBundler.BundleInstantiate a new Bundle object.protected ObjectProcess the specified key in a most optimal way according to the bundle settings.protected MapprocessAll(Collection colKeys) Process a colKeys of specified items in a most optimal way according to the bundle settings.protected abstract ObjectUn-bundle bundled operation.Methods inherited from class com.tangosol.net.cache.AbstractBundler
adjust, getDelayMillis, getOpenBundle, getSizeThreshold, getThreadThreshold, isAllowAutoAdjust, resetStatistics, setAllowAutoAdjust, setDelayMillis, setSizeThreshold, setThreadThreshold, toString, updateStatisticsMethods inherited from class com.tangosol.util.Base
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, newHashMap, newHashMap, newHashSet, newHashSet, 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
-
Constructor Details
-
AbstractKeyBundler
public AbstractKeyBundler()
-
-
Method Details
-
process
Process the specified key in a most optimal way according to the bundle settings.- Parameters:
oKey- the key to process- Returns:
- an execution result according to the caller's contract
-
processAll
Process a colKeys of specified items in a most optimal way according to the bundle settings.- Parameters:
colKeys- the collection of keys to process- Returns:
- an execution result according to the caller's contract
-
bundle
The bundle operation to be performed against a collected set of keys by the concrete AbstractKeyBundler implementations. If an exception occurs during bundle operation, it could be repeated using singleton sets.- Parameters:
colKeys- a key collection to perform the bundled operation for- Returns:
- the Map of operation results
-
unbundle
Un-bundle bundled operation. This operation would be used if an exception occurs during a bundled operation or if the number of active threads is below theThreadThresholdvalue.- Parameters:
oKey- a key to perform the un-bundled operation for- Returns:
- the operation result for the specified key, may be null
-
instantiateBundle
Instantiate a new Bundle object.- Specified by:
instantiateBundlein classAbstractBundler- Returns:
- a new Bundle object
-