StatisticsProvider
WebSphere:*,type=DynaCache
MBean DynaCache
Current settings for the running WebSphere Dynamic Cache (DynaCache). If the cache instance is not specified then the MBean operations by default operate on the base cache instance.
Attribute Summary | |
---|---|
java.lang.Integer | cacheSize The maximum size in entries of the in-memory cache. |
java.lang.Integer | usedCacheSize The number of used cache entries in the in-memory cache. |
java.lang.Boolean | diskOverflow Indicates whether disk based overflow is enabled |
Attributes inherited from MBean StatisticsProvider |
---|
stats |
Operation Summary | |
---|---|
java.lang.String[] | getCacheStatisticNames() Retrieves the names of the available cache statistics. |
java.lang.String[] | getCacheStatisticNames( Retrieve the names of the available cache statistics for the specified cache instance. |
java.lang.String[] | getCacheInstanceNames() Retrieves the names of the available cache instances. |
java.lang.String[] | getAllCacheStatistics() Retrieves all of the available cache statistics for the base cache instance. |
java.lang.String[] | getAllCacheStatistics( Retrieves all of the available cache statistics for the named cache instance. |
java.lang.String[] | getCacheStatistics( Retrieves cache statistics specified by the names array for the base cache instance. |
java.lang.String[] | getCacheStatistics( Retrieves cache statistics specified by the names array for the named cache instance. |
java.lang.String[] | getCacheIDsInMemory( Retrieves all of the cache IDs in memory for the named cache instance that matches the specified regular expression. |
java.lang.String[] | getCacheIDsOnDisk( Retrieves all of the cache IDs on disk for the named cache instance that matches the specified regular expression. |
java.lang.String[] | getCacheIDsInPushPullTable( Retrieves all of the cache IDs in the PushPullTable for the named cache instance that matches the specified regular expression. |
java.lang.String | getCacheEntry( Retrieves the CacheEntry which holds metadata information for the cache ID. |
java.lang.String[] | invalidateCacheIDs( Invalidates all cache entries that match the pattern mapped cache IDs in the named cache instance and all cache entries dependent upon the matched entries in the instance. |
void | clearCache( Clear all cache entries for the named cache instance. |
java.lang.String | getCacheDigest( Returns an MD5 digest of all the cache entries for the named cache instance. |
boolean | compareCaches( Compares the cache digests for the named cache instance on the specified servers and returns true Note that this command can only run in the Deployment Manager. |
java.lang.String[] | getJPACacheStatistics( Retrieves OpenJPA L2 DataCache statistics for the specified DataCache instance. |
java.lang.String[] | getJPACacheStatistics( Retrieves OpenJPA L2 DataCache statistics for the DataCache instance and specified JavaClass. |
Attribute Detail |
---|
public java.lang.Integer cacheSize
The maximum size in entries of the in-memory cache.
Getter:
administrator
operator
configurator
monitor
deployer
adminsecuritymanager
public java.lang.Integer usedCacheSize
The number of used cache entries in the in-memory cache.
Getter:
administrator
operator
configurator
monitor
deployer
adminsecuritymanager
public java.lang.Boolean diskOverflow
Indicates whether disk based overflow is enabled
Getter:
administrator
operator
configurator
monitor
deployer
adminsecuritymanager
Operation Detail |
---|
public java.lang.String[] getCacheStatisticNames()
Retrieves the names of the available cache statistics.
administrator
operator
configurator
monitor
deployer
adminsecuritymanager
public java.lang.String[] getCacheStatisticNames(
java.lang.String cacheInstance
)
Retrieve the names of the available cache statistics for the specified cache instance.
cacheInstance
-
The name of the cache instance.
administrator
operator
configurator
monitor
deployer
adminsecuritymanager
public java.lang.String[] getCacheInstanceNames()
Retrieves the names of the available cache instances.
administrator
operator
configurator
monitor
deployer
adminsecuritymanager
public java.lang.String[] getAllCacheStatistics()
Retrieves all of the available cache statistics for the base cache instance.
administrator
operator
configurator
monitor
deployer
adminsecuritymanager
public java.lang.String[] getAllCacheStatistics(
java.lang.String cacheInstance
)
Retrieves all of the available cache statistics for the named cache instance.
cacheInstance
-
The name of the cache instance.
administrator
operator
configurator
monitor
deployer
adminsecuritymanager
public java.lang.String[] getCacheStatistics(
java.lang.String[] names
)
Retrieves cache statistics specified by the names array for the base cache instance.
names
-
The array of cache statistic names
administrator
operator
configurator
monitor
deployer
adminsecuritymanager
public java.lang.String[] getCacheStatistics(
java.lang.String cacheInstance,
java.lang.String[] names
)
Retrieves cache statistics specified by the names array for the named cache instance.
cacheInstance
-
The name of the cache instance. names
-
The array of cache statistic names
administrator
operator
configurator
monitor
deployer
adminsecuritymanager
public java.lang.String[] getCacheIDsInMemory(
java.lang.String cacheInstance,
java.lang.String pattern
)
Retrieves all of the cache IDs in memory for the named cache instance that matches the specified regular expression. The java.util.regex libraries are for matching. The find() method locates the matching IDs.
cacheInstance
-
The name of the cache instance. pattern
-
A regular expression that is specified as a string.
administrator
operator
configurator
monitor
deployer
adminsecuritymanager
public java.lang.String[] getCacheIDsOnDisk(
java.lang.String cacheInstance,
java.lang.String pattern
)
Retrieves all of the cache IDs on disk for the named cache instance that matches the specified regular expression. The java.util.regex libraries are for matching. The find() method locates the matching IDs. This operation can take a non-deterministic amount of time to complete in some extreme cases.
cacheInstance
-
The name of the cache instance. pattern
-
A regular expression that is specified as a string.
administrator
operator
configurator
monitor
deployer
adminsecuritymanager
public java.lang.String[] getCacheIDsInPushPullTable(
java.lang.String cacheInstance,
java.lang.String pattern
)
Retrieves all of the cache IDs in the PushPullTable for the named cache instance that matches the specified regular expression. The java.util.regex libraries are for matching. The find() method locates the matching IDs.
cacheInstance
-
The name of the cache instance. pattern
-
A regular expression that is specified as a string.
administrator
operator
configurator
monitor
deployer
adminsecuritymanager
public java.lang.String getCacheEntry(
java.lang.String cacheInstance,
java.lang.String cacheID
)
Retrieves the CacheEntry which holds metadata information for the cache ID. Returns null if the CacheEntry is not found. If the entry is found, the following information is returned: Cache ID, User metadata, Priority, Time To Live indicator (TTL), Inactivity, ExpirationTime, Sharing Policy, value Size, value hashcode, A boolean that indicates whether or not the entry exists on disk. A boolean that indicates whether the cache entry skipped memory and was written directly to disk cache. Template IDs, Dependency IDs, Alias IDs, External Cache Group this entry belongs to.
cacheInstance
-
The name of the cache instance. cacheID
-
A cacheID typically returned by the getCacheIDsInMemory or getCacheIDsOnDisk methods.
administrator
operator
configurator
monitor
deployer
adminsecuritymanager
public java.lang.String[] invalidateCacheIDs(
java.lang.String cacheInstance,
java.lang.String pattern,
boolean waitOnInvalidation
)
Invalidates all cache entries that match the pattern mapped cache IDs in the named cache instance and all cache entries dependent upon the matched entries in the instance. Returns the list of cache IDs mapped to the pattern. Dependent cache entries invalidated are not in the list. Matched entries are invalidated in the memory cache and disk cache. To clear a cache, invoke invalidateCacheIDs with a pattern = *. In this case, a list with only the element * is returned.
cacheInstance
-
The name of the cache instance. pattern
-
A regular expression that is specified as a string. waitOnInvalidation
-
True indicates that this method should not return until the invalidations have taken effect. False indicates that the invalidations will be queued for later batch processing. For waitOnInvalidation = true, this method will take a long time to return and potentially could lock the cache and reduce throughput. If waitOnInvalidation = false, this method returns almost immediately, and the invalidates are handled on a separate thread.
administrator
operator
public void clearCache(
java.lang.String cacheInstance
)
Clear all cache entries for the named cache instance.
cacheInstance
-
The name of the cache instance.
administrator
operator
public java.lang.String getCacheDigest(
java.lang.String cacheInstance,
boolean useMemoryCacheDigest,
boolean cacheIDOnly,
boolean debug
)
Returns an MD5 digest of all the cache entries for the named cache instance. Note that the cache key and value objects should override the default java.lang.Object.hashCode() method to get semantic comparability between object instances. This is a CPU and I/O intensive when the useMemoryCacheDigest parameter is set to false. In this case the command will compute a hash of the cached objects on disk.
cacheInstance
-
The name of the cache instance. useMemoryCacheDigest
-
If true, use only the memory cache digest. If false, use the whole cache digest. cacheIDOnly
-
If true, get a digest of all the cache IDs. This will also include a digest from the DRSPushPullTable. If false, get both cache ID and value digest. debug
-
If debug is true, a list of the cache IDs and their hashcodes are written to the SystemOut log.
administrator
operator
configurator
monitor
deployer
adminsecuritymanager
public boolean compareCaches(
java.lang.String cacheInstance,
java.lang.String node1,
java.lang.String server1,
java.lang.String node2,
java.lang.String server2,
boolean useMemoryCacheDigest,
boolean cacheIDOnly,
boolean debug
)
Compares the cache digests for the named cache instance on the specified servers and returns true Note that this command can only run in the Deployment Manager. The cache ID and value objects should override the default java.lang.Object.hashCode() method to get semantic comparability between object instances. If the whole cache digest is chosen by setting the useMemoryCacheDigest parameter to false, this command will compute a hash of the cached objects on disk.leading to heayy CPU and I/O utilization.
cacheInstance
-
The name of the cache instance. node1
-
Name of node on which server1 resides server1
-
Name of server1 node2
-
Name of node on which server2 resides server2
-
Name of server2 useMemoryCacheDigest
-
If true, use only the memory cache digest. If false, use the whole cache digest. cacheIDOnly
-
If true, get a digest of all the cache IDs. This will also include a digest from the DRSPushPullTable. If false, get both cache ID and value digest. debug
-
If debug is true, a list of the cache IDs and their hashcodes are written to the SystemOut log.
administrator
operator
configurator
monitor
deployer
adminsecuritymanager
public java.lang.String[] getJPACacheStatistics(
java.lang.String applicationName,
java.lang.String moduleJarOrWarName,
java.lang.String persistentUnitName,
java.lang.String cacheInstance
)
Retrieves OpenJPA L2 DataCache statistics for the specified DataCache instance.
applicationName
-
Name of the application. moduleJarOrWarName
-
Name of the jar or war module. persistentUnitName
-
The name of the PersistentUnit. cacheInstance
-
The name of the OpenJPA l2 DataCache cache instance.
administrator
operator
configurator
monitor
deployer
adminsecuritymanager
public java.lang.String[] getJPACacheStatistics(
java.lang.String applicationName,
java.lang.String moduleJarOrWarName,
java.lang.String persistentUnitName,
java.lang.String cacheInstance,
java.lang.String entityClassName
)
Retrieves OpenJPA L2 DataCache statistics for the DataCache instance and specified JavaClass.The entity class should be configured in a server scoped shared library.
applicationName
-
Name of the application. moduleJarOrWarName
-
Name of the jar or war module. persistentUnitName
-
The name of the PersistentUnit. cacheInstance
-
The name of the OpenJPA l2 DataCache cache instance. entityClassName
-
Fully Qualified Java Class Name of the Entity class annotated with @DataCache.
administrator
operator
configurator
monitor
deployer
adminsecuritymanager