com.ibm.wsspi.cache
Class DistributedObjectCacheFactory
- java.lang.Object
com.ibm.wsspi.cache.DistributedObjectCacheFactory
- public class DistributedObjectCacheFactory
- extends java.lang.Object
DistributedMap
or DistributedNioMap
created using
this class.
See Also:
DistributedMap
,
DistributedNioMap
Field Summary
Modifier and Type | Field and Description |
---|---|
|
KEY_CACHE_SIZE
Property key to specify cache size.
|
|
KEY_DISABLE_DEPENDENCY_ID
Property key to disble dependency support.
|
|
KEY_DISABLE_TEMPLATES_SUPPORT
Property key to disble template support.
|
|
KEY_DISK_CLEANUP_FREQUENCY
Property key to specify the frequency at which the disk cache cleanup daemon
should remove expired entries from the disk cache.
|
|
KEY_DISK_DELAY_OFFLOAD_DEPID_BUCKETS
Property key to provide a way to limit the buffering of dependency ID information
by specifying an upper bound on the number of dependencies that will be buffered in memory.
|
|
KEY_DISK_DELAY_OFFLOAD_ENTRIES_LIMIT
Property key to provide a way to limit the buffering of dependency
and template information by specify an upper bound on the number of cache entries any
specific dependency can contain for buffering in memory.
|
|
KEY_DISK_DELAY_OFFLOAD_TEMPLATE_BUCKETS
Property key to provide a way to limit the buffering of template information
by specifying an upper bound on the number of templates that will be buffered in memory.
|
|
KEY_DISK_OFFLOAD_LOCATION
Property key to specify the disk offload location.
|
|
KEY_DISKCACHE_ENTRY_SIZE_MB
Property key to specify the limit of disk cache entry size in MB.
|
|
KEY_DISKCACHE_EVICTION_POLICY
Property key to specify the disk cache eviction policy.
|
|
KEY_DISKCACHE_HIGH_THRESHOLD
Property key to specify the high threshold in percentage.
|
|
KEY_DISKCACHE_LOW_THRESHOLD
Property key to specify the low threshold in percentage.
|
|
KEY_DISKCACHE_PERFORMANCE_LEVEL
Property key to specify the disk cache performance level.
|
|
KEY_DISKCACHE_SIZE
Property key to specify the limit of disk cache size in entries.
|
|
KEY_DISKCACHE_SIZE_GB
Property key to specify the limit of disk cache size in GB.
|
|
KEY_ENABLE_CACHE_REPLICATION
Property key to enable cache replication.
|
|
KEY_ENABLE_DISK_OFFLOAD
Property key to disble template support.
|
|
KEY_ENABLE_NIO_SUPPORT
Property key to enable nio support.
|
|
KEY_FLUSH_TO_DISK_ON_STOP
Property key to enable flushing cache contents
to disk when the server is stopped.
|
|
KEY_LRU_TO_DISK_TRIGGER_PERCENT
Property key to specify the limit of percentage of the memory cache size used as a overflow buffer
when disk offload is enabled.
|
|
KEY_MEMORY_CACHE_SIZE_HIGH_THRESHOLD
Property key to specify the memory cache size high threshold in percentage.
|
|
KEY_MEMORY_CACHE_SIZE_IN_MB
Property key to specify a value for the maximum memory cache size in megabytes (MB).
|
|
KEY_MEMORY_CACHE_SIZE_LOW_THRESHOLD
Property key to specify the memory cache low threshold in percentage.
|
|
KEY_REPLICATION_DOMAIN
Property key to specify the replication domain.
|
|
KEY_USE_LISTENER_CONTEXT
Property key to enable listener context on callbacks.
|
|
VALUE_FALSE
Property value for false.
|
|
VALUE_TRUE
Property value for true.
|
Method Summary
Modifier and Type | Method and Description |
---|---|
|
createDistributedObjectCache(java.lang.String name,java.lang.String nameNonPrefixed,java.util.Properties properties)
|
|
getMap(java.lang.String name)
Returns the DistributedMap
instance specified by the given id.
|
|
getMap(java.lang.String name,java.util.Properties properties)
Returns the DistributedMap or DistributedNioMap
instance specified by the given id, using the
the parameters specified in properties.
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail
KEY_CACHE_SIZE
- public static final java.lang.String KEY_CACHE_SIZE
Property key to specify cache size.
Value is string int
KEY_DISABLE_DEPENDENCY_ID
- public static final java.lang.String KEY_DISABLE_DEPENDENCY_ID
Property key to disble dependency support.
Value is VALUE_TRUE or VALUE_FALSE
KEY_DISABLE_TEMPLATES_SUPPORT
- public static final java.lang.String KEY_DISABLE_TEMPLATES_SUPPORT
Property key to disble template support.
Value is VALUE_TRUE or VALUE_FALSE
KEY_ENABLE_DISK_OFFLOAD
- public static final java.lang.String KEY_ENABLE_DISK_OFFLOAD
Property key to disble template support.
Value is VALUE_TRUE or VALUE_FALSE
KEY_ENABLE_NIO_SUPPORT
- public static final java.lang.String KEY_ENABLE_NIO_SUPPORT
Property key to enable nio support.
Value is VALUE_TRUE or VALUE_FALSE
KEY_DISK_OFFLOAD_LOCATION
- public static final java.lang.String KEY_DISK_OFFLOAD_LOCATION
Property key to specify the disk offload location.
Value is string path
KEY_USE_LISTENER_CONTEXT
- public static final java.lang.String KEY_USE_LISTENER_CONTEXT
Property key to enable listener context on callbacks.
Value is VALUE_TRUE or VALUE_FALSE
KEY_FLUSH_TO_DISK_ON_STOP
- public static final java.lang.String KEY_FLUSH_TO_DISK_ON_STOP
Property key to enable flushing cache contents
to disk when the server is stopped.
This property is ignored if disk offload is disabled.
Value is VALUE_TRUE or VALUE_FALSE
KEY_ENABLE_CACHE_REPLICATION
- public static final java.lang.String KEY_ENABLE_CACHE_REPLICATION
Property key to enable cache replication.
Value is VALUE_TRUE or VALUE_FALSE
KEY_REPLICATION_DOMAIN
- public static final java.lang.String KEY_REPLICATION_DOMAIN
Property key to specify the replication domain.
Value is string domain name.
KEY_DISKCACHE_PERFORMANCE_LEVEL
- public static final java.lang.String KEY_DISKCACHE_PERFORMANCE_LEVEL
Property key to specify the disk cache performance level.
Value: 0 - Low Performance and low memory usage;
Value: 1 - Balanced Performance and balanced memory usage (default);
Value: 2 - Custom Performance and custom memory usage;
Value: 3 - High Performance and high memory usage;
KEY_DISK_CLEANUP_FREQUENCY
- public static final java.lang.String KEY_DISK_CLEANUP_FREQUENCY
Property key to specify the frequency at which the disk cache cleanup daemon
should remove expired entries from the disk cache.
Value: positive value in minutes; default = 0 (cleanup is scheduled to run at midnight).
KEY_DISK_DELAY_OFFLOAD_ENTRIES_LIMIT
- public static final java.lang.String KEY_DISK_DELAY_OFFLOAD_ENTRIES_LIMIT
Property key to provide a way to limit the buffering of dependency
and template information by specify an upper bound on the number of cache entries any
specific dependency can contain for buffering in memory. If there are more entries per
dependency than this limit, the dependency/template information is written to disk.
Value: positive value; default = 1000;
KEY_DISK_DELAY_OFFLOAD_DEPID_BUCKETS
- public static final java.lang.String KEY_DISK_DELAY_OFFLOAD_DEPID_BUCKETS
Property key to provide a way to limit the buffering of dependency ID information
by specifying an upper bound on the number of dependencies that will be buffered in memory.
If the count of dependencies exceeds this limit, the excess will be written to disk.
Value: positive value; default = 1000;
KEY_DISK_DELAY_OFFLOAD_TEMPLATE_BUCKETS
- public static final java.lang.String KEY_DISK_DELAY_OFFLOAD_TEMPLATE_BUCKETS
Property key to provide a way to limit the buffering of template information
by specifying an upper bound on the number of templates that will be buffered in memory.
If the count of templates exceeds this limit, the excess will be written to disk.
Value: positive value; default = 1000;
KEY_DISKCACHE_EVICTION_POLICY
- public static final java.lang.String KEY_DISKCACHE_EVICTION_POLICY
Property key to specify the disk cache eviction policy.
Value: 0 (none) - eviction algorithm disabled (default);
Value: 1 (random) - The expired objects are removed first. If the disk size has not reached
the low threshold limit, objects are picked from disk cache in random order until the disk
cache size has reached.
Value: 2 (size based) - The expired objects are removed first. If the disk size has not
reached the low threshold limit, largest-sized objects are removed until the disk cache
size has reached
KEY_DISKCACHE_HIGH_THRESHOLD
- public static final java.lang.String KEY_DISKCACHE_HIGH_THRESHOLD
Property key to specify the high threshold in percentage. It is used to start evicting objects
out of disk cache when one or both of the high thresholds is reached
Value: 0 - 100
KEY_DISKCACHE_LOW_THRESHOLD
- public static final java.lang.String KEY_DISKCACHE_LOW_THRESHOLD
Property key to specify the low threshold in percentage. It is used to bring down the disk cache till the low
threshold is reached.
Value: 0 - 100
KEY_DISKCACHE_SIZE
- public static final java.lang.String KEY_DISKCACHE_SIZE
Property key to specify the limit of disk cache size in entries.
Value: positive integer; default 0 means no limit
KEY_DISKCACHE_SIZE_GB
- public static final java.lang.String KEY_DISKCACHE_SIZE_GB
Property key to specify the limit of disk cache size in GB.
Value: positive integer; default 0 means no limit
KEY_DISKCACHE_ENTRY_SIZE_MB
- public static final java.lang.String KEY_DISKCACHE_ENTRY_SIZE_MB
Property key to specify the limit of disk cache entry size in MB.
Value: positive integer; default 0 means no limit
KEY_LRU_TO_DISK_TRIGGER_PERCENT
- public static final java.lang.String KEY_LRU_TO_DISK_TRIGGER_PERCENT
Property key to specify the limit of percentage of the memory cache size used as a overflow buffer
when disk offload is enabled.
Value: 0 - 100; default 0 means no overflow
KEY_MEMORY_CACHE_SIZE_IN_MB
- public static final java.lang.String KEY_MEMORY_CACHE_SIZE_IN_MB
Property key to specify a value for the maximum memory cache size in megabytes (MB).
Value: positive integer; default: -1 means no limit on memory cache size
KEY_MEMORY_CACHE_SIZE_HIGH_THRESHOLD
- public static final java.lang.String KEY_MEMORY_CACHE_SIZE_HIGH_THRESHOLD
Property key to specify the memory cache size high threshold in percentage.
It is used to start evicting objects out of memory cache until the high threshold is reached
Value: 0 - 100 (default: 95)
KEY_MEMORY_CACHE_SIZE_LOW_THRESHOLD
- public static final java.lang.String KEY_MEMORY_CACHE_SIZE_LOW_THRESHOLD
Property key to specify the memory cache low threshold in percentage.
It is used to prune the memory cache until the low threshold is reached.
Value: 0 - 100 (default: 80)
VALUE_TRUE
- public static final java.lang.String VALUE_TRUE
Property value for true.
VALUE_FALSE
- public static final java.lang.String VALUE_FALSE
Property value for false.
Method Detail
getMap
- public static com.ibm.websphere.cache.DistributedObjectCache getMap( java.lang.String name)
Returns the DistributedMap
instance specified by the given id. If
the given instance has not yet been created, then a new instance
is created using the default parameters.
Parameters:
name
- instance name Returns:
A DistributedMap instance
See Also:
getMap
- public static com.ibm.websphere.cache.DistributedObjectCache getMap( java.lang.String name,
- java.util.Properties properties)
Returns the DistributedMap or DistributedNioMap
instance specified by the given id, using the
the parameters specified in properties. If the given
instance has not yet been created, then a new
instance is created using the parameters
specified in the properties object. Use the
various KEY_xxx and VALUE_xxx
constants to populate the passed properties object.
Parameters:
name
- instance name properties
- Returns:
A DistributedObjectCache instance
createDistributedObjectCache
- public static com.ibm.websphere.cache.DistributedObjectCache createDistributedObjectCache( java.lang.String name,
- java.lang.String nameNonPrefixed,
- java.util.Properties properties)