Skip Headers

# TopLink Coordinated Cache

Previous

Next

Consider multiple TopLink applications (each running on its own application server instance) configured to use a distributed, coordinated cache (as described in "Understanding Cache Coordination"). A TopLink application instance first commits changes to its own cache before the change is distributed to other caches. Because cache coordination is not instantaneous, there is a possibility that one TopLink application instance may read an older version of an object from its cache before a cache coordination message is received.

To provide your TopLink application with the most up-to-date version of an object use the descriptor isolated cache option (see "Cache Isolation"), as well as cache invalidation (see "Cache Invalidation").

You can also avoid stale data by using `Descriptor` methods `alwaysRefreshCache` and `disableCacheHits`. For more information on the `disableCacheHits` method, see "Managing Cache Access".

Caution: Using `Descriptor` methods `alwaysRefreshCache` and `disableCacheHits` will result in frequent database hits. Use only when absolutely necessary.