A servlet cache instance is a location, in addition to the default shared dynamic cache, where dynamic cache can store, distribute, and share data. By using servlet cache instances, your applications have greater flexibility and better tuning of the cache resources. The Java Naming and Directory Interface (JNDI) name specified for the cache instance is mapped to the name attribute in the <cache-instance> tag in the cachespec.xml configuration file.
To view this administrative console page, click Resources > Cache instances > Servlet cache instances > cache_instance_name.
Specifies the required display name for the resource.
Specifies the Java Naming and Directory Interface (JNDI) name for the resource. Specify this name in the name attribute field in the <cache-instance> tag in the cachespec.xml configuration file. This tag is used to find the particular cache instance in which to store cache entries.
Specifies a description for the resource. This field is optional.
Specifies a category string to classify or group the resource. This field is optional.
Specifies a positive integer for the maximum number of entries the cache holds. The cache size is usually in the thousands.
Default | 2000 |
Range | 100 - no set maximum value |
Specifies the default priority for servlets that can be cached. This value determines how long an entry stays in a full cache.
The recommended value is one.
Specifies if disk offloading is enabled.
If you have disk offload disabled, when a new entry is created while the cache is full, the priorities are configured for each entry and the least recently used algorithm are used to remove the entry from the cache in memory. If you enable disk offload, the entry that would be removed from the cache is copied to the local file system. The location of the file is specified by the disk offload location.
Default | false |
Specifies the directory used for disk offload.
If disk offload location is not specified, the default location, ${WAS_TEMP_DIR}/node/server name/_dynacache/cache JNDI name will be used. If disk offload location is specified, the node, server name, and cache instance name are appended. For example, ${USER_INSTALL_ROOT}/diskoffload generates the location as ${USER_INSTALL_ROOT}/diskoffload/node/server name/cache JNDI name. This value is ignored if disk offload is not enabled.
Specifies if in-memory cached objects are saved to disk when the server is stopped. This value is ignored if Enable Disk Offload is not selected.
Default | false |
Set this value to true to have invalidation events sent to registered invalidation listeners using the Java 2 Platform, Enterprise Edition (J2EE) context of the listener. If you want to use listener J2EE context for callback, set this value to true. If you want to use the caller thread context for callback, set this to false.
Specifies that the dynamic cache service, supports cache entry dependency IDs. Disable this option if you do not need to use dependency IDs. Dependency IDs specify additional cache group identifiers that associate multiple cache entries to the same group identifier in your cache policy.
This option might not be available for cache instances that were created with a previous version of WebSphere Application Server.
Default | true |
Use cache replication to enable sharing of cache IDs, cache entries, and cache invalidations with other servers in the same replication domain.
This option might be unavailable for cache instances created with a previous version of WebSphere Application Server.
Specifies a replication domain from which your data is replicated.
Specifies a replication domain from which your data is replicated. Choose from any replication domains that have been defined. If there are no replication domains listed, you must create one during cluster creation or manually in the administrative console by clicking Environment > Internal replication domains > New. The replication domain you choose to use with the dynamic cache service must be using a Full group replica. Do not share replication domains between replication consumers. Dynamic cache should use a different replication domain from session manager or stateful session beans.
Specifies the global sharing policy for this cache instance.
Specifies the time in seconds to wait before pushing new or modified cache entries to other servers.
A value of 0 (zero) means send the cache entries immediately. Setting this property to a value greater than 0 (zero) causes a "batch" push of all cache entries that are created or modified during the time period. The default is 0 (zero).
Configuration tab
Specifies a value for the maximum disk cache size in MB. When you select this option, you can specify a positive integer value. Leaving this option unselected indicates an unlimited size. This setting applies only if enable disk offload is specified for the cache.
Value | 0 to MAXINT. A value of 0 indicates unlimited size. |
Specifies a value for the maximum disk cache size in number of entries. When you select this option, you can specify a positive integer value. Leaving this option unselected indicates an unlimited size. This setting applies only if enable disk offload is specified for the cache.
Value | 0 to MAXINT. A value of 0 indicates unlimited size. |
Specifies a value for the maximum size of an individual cache entry in MB. Any cache entry larger than this, when evicted from memory, will not be offloaded to disk. When you select this option, you can specify a positive integer value. Leaving this option unselected indicates an unlimited size. This setting applies only if enable disk offload is specified for the cache.
Value | 0 to MAXINT. A value of 0 indicates unlimited size. |
Specifies the level of performance that is required by the disk cache. This setting applies only if enableDiskOffload is specified for the cache. Performance levels determine how memory resources should be used on background activity such as cache cleanup, expiration, garbage collection, and so on. This setting applies only if enable disk offload is specified for the cache.
High performance | Indicates that all metadata will be kept in memory. |
Medium performance | Indicates some metadata will be kept in memory. This is the default performance setting and will provide an optimal balance of performance and memory usage for most users. |
Low performance | Indicates that limited metadata will be kept in memory. |
Custom performance | Indicates that the administrator will explicitly configure the memory settings that will be used to support the above background activity. The administrator sets these values using the DiskCacheCustomPerformanceSettings object. |
Specifies a value for the disk cache cleanup frequency, in minutes. If this value is set to 0, the cleanup runs only at midnight. This setting applies only when the Disk Offload Performance Level is LOW, BALANCED, or CUSTOM. The HIGH performance level does not require disk cleanup, and this value is ignored.
Value | 0 to 1440 |
Specifies the eviction algorithm that the disk cache will use to evict entries once the high threshold is reached. This setting applies only if enable disk offload is specified for the cache.
None | No eviction policy, so the disk cache can grow until it reaches its limit at which time the dynamic cache service stops writing to disk |
Random | When the disk size reaches a high threshold limit, the disk cache garbage collector wakes up and randomly picks entries on the disk and evicts them until the size reaches a low threshold limit. |
Size | When the disk size reaches a high threshold limit, the disk cache garbge collector wakes up and picks the largest entries on the disk and evicts them until the disk size reaches a low threshold limit. |
Specifies when the eviction policy is executed. The threshold is expressed in terms of the percentage of the disk cache size in MB or entries. The lower value is used limit disk cache size in MB and limit disk cache size in entries are specified. This setting does not apply when the disk cache eviction policy is set to none.
Values | 1 to 100 |
Specifies when the eviction policy will terminate. The threshold is expressed in terms of the percentage of the disk cache size in MB or entries. The lower value is used limit disk cache size in MB and limit disk cache size in entries are specified. This setting does not apply when the disk cache eviction policy is set to none.
Values | 1 to 100 |
Related tasks
Using the DistributedMap and DistributedObjectCache interfaces for
the dynamic cache
Related reference
Object cache instance collection
Object cache instance settings
Servlet cache instance collection