org.apache.geode.cache30

## Class RegionTestCase

- java.lang.Object
- - org.apache.geode.test.dunit.internal.JUnit4DistributedTestCase
  - - org.apache.geode.test.dunit.cache.internal.JUnit4CacheTestCase
    - - org.apache.geode.cache30.RegionTestCase

- All Implemented Interfaces:
    java.io.Serializable, org.apache.geode.test.dunit.cache.internal.CacheTestFixture, org.apache.geode.test.dunit.internal.DistributedTestFixture
  Direct Known Subclasses:
    MultiVMRegionTestCase

      public abstract class RegionTestCase
      extends org.apache.geode.test.dunit.cache.internal.JUnit4CacheTestCase

  An abstract class whose test methods test the functionality of a region regardless of its scope.

  This class also contains functionality that is used by subclasses. See `getRegionAttributes()`. TODO:davidw: Test `CacheStatistics`

  Since:
    GemFire 3.0
  See Also:
    Serialized Form

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class and Description
    --- | ---
    `protected class` | `RegionTestCase.TestExpiry`

  - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `protected int` | `eventCount`
    `static Region` | `preSnapshotRegion` Tests basic creation and loading of a snapshot from perspective of single VM

    - ### Fields inherited from class org.apache.geode.test.dunit.cache.internal.JUnit4CacheTestCase

      `cache`

    - ### Fields inherited from class org.apache.geode.test.dunit.internal.JUnit4DistributedTestCase

      `system, testNameForDistributedTestCase`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `RegionTestCase()`

  - ### Method Summary

    All Methods Static Methods Instance Methods Abstract Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected <K,V> Region<K,V>` | `createRegion(java.lang.String name)` Returns a region with the given name and the attributes for this test.
    `protected <K,V> Region<K,V>` | `createRootRegion()`
    `static boolean` | `entryIsLocal(Region.Entry re)`
    `protected void` | `flushIfNecessary(Region r)` Make sure all messages done on region r have been processed on the remote side.
    `protected abstract <K,V> RegionAttributes<K,V>` | `getRegionAttributes()` Returns the attributes of a region to be tested by this test.
    `protected void` | `pauseIfNecessary()` pauses only if no ack
    `protected void` | `pauseIfNecessary(int ms)`
    `void` | `postTearDownCacheTestCase()`
    `protected void` | `postTearDownRegionTestCase()`
    `void` | `remoteTestPostSnapshot(java.lang.String name, boolean isController, boolean isRoot)`
    `protected boolean` | `supportsLocalDestroyAndLocalInvalidate()` Indicate whether localDestroy and localInvalidate are supported
    `protected boolean` | `supportsSubregions()` Indicate whether subregions are supported
    `void` | `testBadRegionAccess()` Tests that creating or getting entries at an improper time throws exceptions.
    `void` | `testCloseRegion()` Tests closing a region, and checks different behavior when this is a disk region with persistBackup.
    `void` | `testContainsKey()` Tests that creating an entry in a region actually creates it
    `void` | `testCreateSubregions()` Tests creating subregions.
    `void` | `testCustomEntryIdleReset()` Verify that a get or put resets the idle time on an entry
    `void` | `testCustomEntryIdleTimeout1()` Verify that special entries expire but other entries in the region don't
    `void` | `testCustomEntryIdleTimeout2()` Verify that special entries don't expire but other entries in the region do
    `void` | `testCustomEntryIdleTimeout3()` Configure custome entry expiration with an idle time.
    `void` | `testCustomEntryTtl1()` Verify that special entries expire but other entries in the region don't
    `void` | `testCustomEntryTtl2()` Verify that special entries don't expire but other entries in the region do
    `void` | `testCustomEntryTtl3()` Expire an entry with a custom expiration.
    `void` | `testCustomIdleOnce()` Verify that expiry is calculatod only once on an entry
    `void` | `testDestroyEntry()` Tests `destroying` an entry and attempting to access it afterwards.
    `void` | `testDestroyRegion()` Tests destroying an entire region and that accessing it after it has been destory causes a `RegionDestroyedException`.
    `void` | `testEntries()` Tests the `Region.entrySet(boolean)` method without recursion
    `void` | `testEntriesRecursive()` Tests the `Region.entrySet(boolean)` method with recursion
    `void` | `testEntryExpirationAfterMutate()`
    `void` | `testEntryFromLoadTtlInvalidate()` Tests that an entry whose value is loaded into a region expires with an invalidation after a given time to live.
    `void` | `testEntryIdleDestroy()` Tests that an entry in a region that remains idle for a given amount of time is destroyed.
    `void` | `testEntryIdleInvalidate()` Tests that an entry in a local region that remains idle for a given amount of time is invalidated.
    `void` | `testEntryIdleReset()` Verify that accessing an entry resets its idle time
    `void` | `testEntryIdleTimeout3()` Configure entry expiration with a idle time.
    `void` | `testEntryIdleTtl()` Verify that accessing an entry does not delay expiration due to TTL
    `void` | `testEntryTtl3()` Configure entry expiration with a ttl time.
    `void` | `testEntryTtlDestroy()` Tests that an entry in a region expires with a destroy after a given time to live.
    `void` | `testEntryTtlInvalidate()` Tests that an entry in a region expires with an invalidation after a given time to live.
    `void` | `testEntryUserAttribute()` Tests a region entry's user attribute
    `void` | `testGetCache()` Tests the `Region.getCache()` method (for what it's worth)
    `void` | `testGetName()` Tests the `Region.getName()` method
    `void` | `testGetParentRegion()` Tests the `Region.getParentRegion()` method
    `void` | `testGetPathFromRoot()` Tests the `Region.getFullPath()` method
    `void` | `testInvalidateEntry()` Tests invalidating a region entry
    `void` | `testInvalidateRegion()` Tests invalidating an entire region
    `void` | `testKeys()` Tests the `Region.keySet()` method.
    `void` | `testLocalDestroyEntry()` Tests `locally destroying` an entry and attempting to access it afterwards.
    `void` | `testLocalDestroyRegion()` Tests locally destroying an entire region and that accessing it after it has been destory causes a `RegionDestroyedException`.
    `void` | `testLocalInvalidateEntry()` Tests locally invalidating a region entry
    `void` | `testLocalInvalidateRegion()` Tests locally invalidating an entire region
    `void` | `testNulls()` Tests that sending `null` to various APIs throws the appropriate exception.
    `void` | `testPutNonExistentEntry()` Tests that `Region.put(K, V)` on a previously non-existent region entry creates it.
    `void` | `testRegionExpirationAfterMutate()`
    `void` | `testRegionIdleDestroy()` Tests that a region expires with a destruction after a given idle time.
    `void` | `testRegionIdleInvalidate()` Tests that a region that remains idle for a given amount of time is invalidated.
    `void` | `testRegionTtlDestroy()` Tests that a region expires with a destruction after a given time to live.
    `void` | `testRegionTtlInvalidate()` Tests that a region expires with an invalidation after a given time to live.
    `void` | `testRegionUserAttribute()` Tests a `Region`'s user attribute
    `void` | `testRootSnapshot()`
    `void` | `testSnapshot()`
    `void` | `testSubregions()` Tests the `Region.subregions(boolean)` method without recursion
    `void` | `testSubregionsRecursive()` Tests the `Region.subregions(boolean)` method with recursion
    `void` | `testValues()` Tests the `Region.values()` method without recursion
    `protected void` | `waitForDestroy(Region.Entry entry, long p_tilt)` Since tilt is the earliest time we expect, one must check the current time before invoking the operation intended to keep the entry alive.
    `protected void` | `waitForDestroy(Region.Entry entry, long p_tilt, int pauseMs)` Since tilt is the earliest time we expect, one must check the current time before invoking the operation intended to keep the entry alive.
    `protected void` | `waitForInvalidate(Region.Entry entry, long p_tilt)` Since tilt is the earliest time we expect, one must check the current time before invoking the operation intended to keep the entry alive.
    `protected void` | `waitForInvalidate(Region.Entry entry, long p_tilt, int pauseMs)` Since tilt is the earliest time we expect, one must check the current time before invoking the operation intended to keep the entry alive.
    `protected void` | `waitForRegionDestroy(Region region, long p_tilt)` Since tilt is the earliest time we expect, one must check the current time before invoking the operation intended to keep the region alive.

    - ### Methods inherited from class org.apache.geode.test.dunit.cache.internal.JUnit4CacheTestCase

      `addExceptionTag1, basicGetCache, beginCacheXml, closeAllCache, closeCache, createExpiryRootRegion, createLonerCache, createRegion, createRegion, createRootRegion, createRootRegion, finishCacheXml, finishCacheXml, getCache, getCache, getCache, getCache, getCache, getClientCache, getClientCache, getDiskDir, getDiskDirs, getGemfireCache, getRootRegion, getRootRegion, hasCache, preTearDown, preTearDownCacheTestCase, removeExceptionTag1`

    - ### Methods inherited from class org.apache.geode.test.dunit.internal.JUnit4DistributedTestCase

      `basicGetSystem, cleanDiskDirs, cleanupAllVms, deleteBACKUPDiskStoreFile, destroyRegions, disconnectAllFromDS, disconnectFromDS, getBlackboard, getDistributedSystemProperties, getLonerSystem, getName, getSystem, getSystem, getSystemStatic, getTestClass, getTestMethodName, getUniqueName, initializeBlackboard, initializeDistributedTestCase, isConnectedToDS, nullSystem, postSetUp, postTearDown, postTearDownAssertions, preSetUp, preTearDownAssertions, setSystem, setUpDistributedTestCase, tearDownDistributedTestCase`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

    - ### Methods inherited from interface org.apache.geode.test.dunit.internal.DistributedTestFixture

      `getDistributedSystemProperties, getName, postSetUp, postTearDown, postTearDownAssertions, preSetUp, preTearDownAssertions`

- - ### Field Detail

    - #### eventCount

          protected volatile int eventCount

    - #### preSnapshotRegion

          public static Region preSnapshotRegion

      Tests basic creation and loading of a snapshot from perspective of single VM

  - ### Constructor Detail

    - #### RegionTestCase

          public RegionTestCase()

  - ### Method Detail

    - #### postTearDownCacheTestCase

          public final void postTearDownCacheTestCase()
                                               throws java.lang.Exception

      Specified by:
        `postTearDownCacheTestCase` in interface `org.apache.geode.test.dunit.cache.internal.CacheTestFixture`
      Overrides:
        `postTearDownCacheTestCase` in class `org.apache.geode.test.dunit.cache.internal.JUnit4CacheTestCase`
      Throws:
        `java.lang.Exception`

    - #### postTearDownRegionTestCase

          protected void postTearDownRegionTestCase()
                                             throws java.lang.Exception

      Throws:
        `java.lang.Exception`

    - #### createRegion

          protected <K,V> Region<K,V> createRegion(java.lang.String name)
                                            throws CacheException

      Returns a region with the given name and the attributes for this test.
      Throws:
        `CacheException`
      See Also:
        `getRegionAttributes()`

    - #### createRootRegion

          protected <K,V> Region<K,V> createRootRegion()
                                                throws CacheException

      Throws:
        `CacheException`

    - #### getRegionAttributes

          protected abstract <K,V> RegionAttributes<K,V> getRegionAttributes()

      Returns the attributes of a region to be tested by this test. Note that the decision as to which attributes are used is left up to the concrete subclass.

    - #### pauseIfNecessary

          protected void pauseIfNecessary()

      pauses only if no ack

    - #### pauseIfNecessary

          protected void pauseIfNecessary(int ms)

    - #### flushIfNecessary

          protected void flushIfNecessary(Region r)

      Make sure all messages done on region r have been processed on the remote side.

    - #### testContainsKey

          public void testContainsKey()
                               throws CacheException

      Tests that creating an entry in a region actually creates it
      Throws:
        `CacheException`
      See Also:
        `Region.containsKey(java.lang.Object)`, `Region.containsValueForKey(java.lang.Object)`

    - #### testBadRegionAccess

          public void testBadRegionAccess()
                                   throws CacheException

      Tests that creating or getting entries at an improper time throws exceptions.
      Throws:
        `CacheException`
      See Also:
        `Region.get(java.lang.Object)`, `Region.getEntry(java.lang.Object)`, `Region.create(K, V)`

    - #### testPutNonExistentEntry

          public void testPutNonExistentEntry()
                                       throws CacheException

      Tests that `Region.put(K, V)` on a previously non-existent region entry creates it.
      Throws:
        `CacheException`

    - #### supportsSubregions

          protected boolean supportsSubregions()

      Indicate whether subregions are supported

    - #### supportsLocalDestroyAndLocalInvalidate

          protected boolean supportsLocalDestroyAndLocalInvalidate()

      Indicate whether localDestroy and localInvalidate are supported
      Returns:
        true if they are supported

    - #### testNulls

          public void testNulls()
                         throws CacheException

      Tests that sending `null` to various APIs throws the appropriate exception.
      Throws:
        `CacheException`

    - #### testCreateSubregions

          public void testCreateSubregions()
                                    throws CacheException

      Tests creating subregions. Note that this tests accesses the Region's `statistics`, so the region must have been created with statistics enabled.
      Throws:
        `CacheException`

    - #### entryIsLocal

          public static boolean entryIsLocal(Region.Entry re)

    - #### testDestroyEntry

          public void testDestroyEntry()
                                throws CacheException

      Tests `destroying` an entry and attempting to access it afterwards.
      Throws:
        `CacheException`

    - #### testDestroyRegion

          public void testDestroyRegion()
                                 throws CacheException

      Tests destroying an entire region and that accessing it after it has been destory causes a `RegionDestroyedException`.
      Throws:
        `CacheException`
      See Also:
        `Region.destroyRegion()`

    - #### testEntries

          public void testEntries()
                           throws CacheException

      Tests the `Region.entrySet(boolean)` method without recursion
      Throws:
        `CacheException`

    - #### testEntriesRecursive

          public void testEntriesRecursive()
                                    throws CacheException

      Tests the `Region.entrySet(boolean)` method with recursion
      Throws:
        `CacheException`

    - #### testGetCache

          public void testGetCache()
                            throws CacheException

      Tests the `Region.getCache()` method (for what it's worth)
      Throws:
        `CacheException`

    - #### testGetName

          public void testGetName()
                           throws CacheException

      Tests the `Region.getName()` method
      Throws:
        `CacheException`

    - #### testGetPathFromRoot

          public void testGetPathFromRoot()
                                   throws CacheException

      Tests the `Region.getFullPath()` method
      Throws:
        `CacheException`

    - #### testGetParentRegion

          public void testGetParentRegion()
                                   throws CacheException

      Tests the `Region.getParentRegion()` method
      Throws:
        `CacheException`

    - #### testRegionUserAttribute

          public void testRegionUserAttribute()
                                       throws CacheException

      Tests a `Region`'s user attribute
      Throws:
        `CacheException`
      See Also:
        `Region.setUserAttribute(java.lang.Object)`

    - #### testEntryUserAttribute

          public void testEntryUserAttribute()
                                      throws CacheException

      Tests a region entry's user attribute
      Throws:
        `CacheException`

    - #### testInvalidateEntry

          public void testInvalidateEntry()
                                   throws CacheException

      Tests invalidating a region entry
      Throws:
        `CacheException`

    - #### testInvalidateRegion

          public void testInvalidateRegion()
                                    throws CacheException

      Tests invalidating an entire region
      Throws:
        `CacheException`

    - #### testKeys

          public void testKeys()
                        throws CacheException

      Tests the `Region.keySet()` method.
      Throws:
        `CacheException`

    - #### testLocalDestroyEntry

          public void testLocalDestroyEntry()
                                     throws CacheException

      Tests `locally destroying` an entry and attempting to access it afterwards. (Not too useful with a `LOCAL` region.)
      Throws:
        `CacheException`

    - #### testLocalDestroyRegion

          public void testLocalDestroyRegion()
                                      throws CacheException

      Tests locally destroying an entire region and that accessing it after it has been destory causes a `RegionDestroyedException`.
      Throws:
        `CacheException`
      See Also:
        `Region.localDestroyRegion()`

    - #### testCloseRegion

          public void testCloseRegion()
                               throws CacheException

      Tests closing a region, and checks different behavior when this is a disk region with persistBackup.
      Throws:
        `CacheException`

    - #### testLocalInvalidateEntry

          public void testLocalInvalidateEntry()
                                        throws CacheException

      Tests locally invalidating a region entry
      Throws:
        `CacheException`

    - #### testLocalInvalidateRegion

          public void testLocalInvalidateRegion()
                                         throws CacheException

      Tests locally invalidating an entire region
      Throws:
        `CacheException`

    - #### testSubregions

          public void testSubregions()
                              throws CacheException

      Tests the `Region.subregions(boolean)` method without recursion
      Throws:
        `CacheException`

    - #### testSubregionsRecursive

          public void testSubregionsRecursive()
                                       throws CacheException

      Tests the `Region.subregions(boolean)` method with recursion
      Throws:
        `CacheException`

    - #### testValues

          public void testValues()
                          throws CacheException

      Tests the `Region.values()` method without recursion
      Throws:
        `CacheException`

    - #### waitForInvalidate

          protected void waitForInvalidate(Region.Entry entry,
                                           long p_tilt)

      Since tilt is the earliest time we expect, one must check the current time before invoking the operation intended to keep the entry alive.
      Parameters:
        `entry` - entry we want to be invalidated
        `p_tilt` - earliest time we expect to see the invalidate

    - #### waitForInvalidate

          protected void waitForInvalidate(Region.Entry entry,
                                           long p_tilt,
                                           int pauseMs)

      Since tilt is the earliest time we expect, one must check the current time before invoking the operation intended to keep the entry alive.
      Parameters:
        `entry` - entry we want to be invalidated
        `p_tilt` - earliest time we expect to see the invalidate
        `pauseMs` - the number of milliseconds to pause before checking again

    - #### waitForDestroy

          protected void waitForDestroy(Region.Entry entry,
                                        long p_tilt)

      Since tilt is the earliest time we expect, one must check the current time before invoking the operation intended to keep the entry alive.
      Parameters:
        `entry` - entry we want to be invalidated
        `p_tilt` - earliest time we expect to see the invalidate

    - #### waitForDestroy

          protected void waitForDestroy(Region.Entry entry,
                                        long p_tilt,
                                        int pauseMs)

      Since tilt is the earliest time we expect, one must check the current time before invoking the operation intended to keep the entry alive.
      Parameters:
        `entry` - entry we want to be invalidated
        `p_tilt` - earliest time we expect to see the invalidate
        `pauseMs` - the number of milliseconds to pause before checking again

    - #### waitForRegionDestroy

          protected void waitForRegionDestroy(Region region,
                                              long p_tilt)

      Since tilt is the earliest time we expect, one must check the current time before invoking the operation intended to keep the region alive.
      Parameters:
        `region` - region we want to be destroyed
        `p_tilt` - earliest time we expect to see the destroy

    - #### testEntryTtlInvalidate

          public void testEntryTtlInvalidate()
                                      throws CacheException

      Tests that an entry in a region expires with an invalidation after a given time to live.
      Throws:
        `CacheException`

    - #### testCustomEntryTtl1

          public void testCustomEntryTtl1()

      Verify that special entries expire but other entries in the region don't

    - #### testCustomEntryTtl2

          public void testCustomEntryTtl2()

      Verify that special entries don't expire but other entries in the region do

    - #### testCustomEntryTtl3

          public void testCustomEntryTtl3()

      Expire an entry with a custom expiration. Set a new custom expiration, create the same entry again, make sure it observes the new expiration

    - #### testEntryTtl3

          public void testEntryTtl3()

      Configure entry expiration with a ttl time. Create an entry and records its scheduled expiration time. Then mutate the region expiration configuration and confirm that the entry's expiration time is rescheduled.

    - #### testEntryFromLoadTtlInvalidate

          public void testEntryFromLoadTtlInvalidate()
                                              throws CacheException,
                                                     java.lang.InterruptedException

      Tests that an entry whose value is loaded into a region expires with an invalidation after a given time to live.
      Throws:
        `CacheException`
        `java.lang.InterruptedException`

    - #### testEntryTtlDestroy

          public void testEntryTtlDestroy()
                                   throws CacheException,
                                          java.lang.InterruptedException

      Tests that an entry in a region expires with a destroy after a given time to live.
      Throws:
        `CacheException`
        `java.lang.InterruptedException`

    - #### testRegionTtlInvalidate

          public void testRegionTtlInvalidate()
                                       throws CacheException,
                                              java.lang.InterruptedException

      Tests that a region expires with an invalidation after a given time to live.
      Throws:
        `CacheException`
        `java.lang.InterruptedException`

    - #### testRegionTtlDestroy

          public void testRegionTtlDestroy()
                                    throws CacheException,
                                           java.lang.InterruptedException

      Tests that a region expires with a destruction after a given time to live.
      Throws:
        `CacheException`
        `java.lang.InterruptedException`

    - #### testEntryIdleInvalidate

          public void testEntryIdleInvalidate()
                                       throws CacheException,
                                              java.lang.InterruptedException

      Tests that an entry in a local region that remains idle for a given amount of time is invalidated.
      Throws:
        `CacheException`
        `java.lang.InterruptedException`

    - #### testCustomEntryIdleTimeout1

          public void testCustomEntryIdleTimeout1()

      Verify that special entries expire but other entries in the region don't

    - #### testCustomEntryIdleTimeout2

          public void testCustomEntryIdleTimeout2()

      Verify that special entries don't expire but other entries in the region do

    - #### testCustomEntryIdleTimeout3

          public void testCustomEntryIdleTimeout3()

      Configure custome entry expiration with an idle time. Create an entry and records its scheduled expiration time. Then mutate the region expiration configuration and confirm that the entry's expiration time is rescheduled.

    - #### testEntryIdleTimeout3

          public void testEntryIdleTimeout3()

      Configure entry expiration with a idle time. Create an entry and records its scheduled expiration time. Then mutate the region expiration configuration and confirm that the entry's expiration time is rescheduled.

    - #### testCustomIdleOnce

          public void testCustomIdleOnce()

      Verify that expiry is calculatod only once on an entry

    - #### testCustomEntryIdleReset

          public void testCustomEntryIdleReset()

      Verify that a get or put resets the idle time on an entry

    - #### testEntryIdleDestroy

          public void testEntryIdleDestroy()
                                    throws java.lang.Exception

      Tests that an entry in a region that remains idle for a given amount of time is destroyed.
      Throws:
        `java.lang.Exception`

    - #### testEntryIdleReset

          public void testEntryIdleReset()
                                  throws java.lang.Exception

      Verify that accessing an entry resets its idle time
      Throws:
        `java.lang.Exception`

    - #### testEntryExpirationAfterMutate

          public void testEntryExpirationAfterMutate()
                                              throws CacheException,
                                                     java.lang.InterruptedException

      Throws:
        `CacheException`
        `java.lang.InterruptedException`

    - #### testEntryIdleTtl

          public void testEntryIdleTtl()

      Verify that accessing an entry does not delay expiration due to TTL

    - #### testRegionExpirationAfterMutate

          public void testRegionExpirationAfterMutate()
                                               throws CacheException,
                                                      java.lang.InterruptedException

      Throws:
        `CacheException`
        `java.lang.InterruptedException`

    - #### testRegionIdleInvalidate

          public void testRegionIdleInvalidate()
                                        throws java.lang.InterruptedException,
                                               CacheException

      Tests that a region that remains idle for a given amount of time is invalidated. Also tests that accessing an entry of a region or a subregion counts as an access.
      Throws:
        `java.lang.InterruptedException`
        `CacheException`

    - #### testRegionIdleDestroy

          public void testRegionIdleDestroy()
                                     throws CacheException,
                                            java.lang.InterruptedException

      Tests that a region expires with a destruction after a given idle time.
      Throws:
        `CacheException`
        `java.lang.InterruptedException`

    - #### testSnapshot

          public void testSnapshot()
                            throws java.io.IOException,
                                   CacheException,
                                   java.lang.ClassNotFoundException

      Throws:
        `java.io.IOException`
        `CacheException`
        `java.lang.ClassNotFoundException`

    - #### testRootSnapshot

          public void testRootSnapshot()
                                throws java.io.IOException,
                                       CacheException,
                                       java.lang.ClassNotFoundException

      Throws:
        `java.io.IOException`
        `CacheException`
        `java.lang.ClassNotFoundException`

    - #### remoteTestPostSnapshot

          public void remoteTestPostSnapshot(java.lang.String name,
                                             boolean isController,
                                             boolean isRoot)
                                      throws CacheException

      Throws:
        `CacheException`