Accessing a global cache by using a Mapping node
You can use a Mapping node to interact with a map in the embedded global cache, external Redis global cache, embedded WebSphere® eXtreme Scale grid, or external WebSphere eXtreme Scale grid.
Before you begin
- Read the concept information in Data caching overview.
- Ensure that the embedded or external cache is available. The embedded
cache is disabled by default.
To use the cache, select an integration node level cache policy; see Configuring the embedded global cache.
- If you are connecting to an external Redis global cache, see Connecting to an external Redis global cache.
- If you are connecting to an external WebSphere eXtreme Scale grid, create a policy (see Creating policies with the IBM App Connect Enterprise Toolkit) to define how the connection is made. For more information, see Connecting to external WebSphere eXtreme Scale grids (deprecated).
About this task
You can use a Mapping node to set the policy name for an external global cache, by setting the cacheName property in the map. You can either set the value of the property to the name of the policy project for the relevant external global cache connection policy or leave it blank to use the embedded global cache.
You can use a Cache Put transform in a Mapping node to store data in the global cache; see Adding key-value pairs to the global cache by using a Mapping node.
You can use a Cache Get transform in a Mapping node to retrieve data from the cache for processing or routing; see Retrieving a value from the global cache by using a Mapping node.
You can use a Cache Remove transform in a Mapping node to remove a key-value pair from the cache; see Removing a key-value pair from the global cache by using a Mapping node.
You can specify how long data remains in the global cache before it is removed automatically by setting a Time To Live (TTL) value; see Specifying how long data remains in the global cache by using the Mapping node.
If you want to handle any exceptions that are returned by the Cache transform, you can add a Cache Failure transform to the Cache transform group; see Handling global cache exceptions in a graphical data map.