Integration Server 10.3 | Built-In Services Reference Guide | Cache Folder | Summary of Elements in this Folder | pub.cache:put
 
pub.cache:put
WmPublic. Populates a cached element with a specified key-value pair.
Input Parameters
cacheManagerName
String Name of the cache manager that manages the cache. This parameter is case sensitive.
cacheName
String Name of the cache in which to put the element. This parameter is case sensitive.
key
Object Key of the cached element.
value
Object Value of the cached element.
useWriter
String Optional. Indicates whether to use a cache writer to populate the value of the cached element in the system-of-record (SOR). Set to:
*true to use a cache writer to add the value to the cached element and the SOR.
*false to add the value to the cached element without writing to the SOR. This is the default setting.
Note:
If the value already exists in the cache, pub.cache:put replaces the value.
Output Parameters
None.
Usage Notes
If your cache is a distributed cache or is configured to use disk store or BigMemory, key and value must be Java Serializable objects.
If the element with the specified key does not already exist in the cache, the pub.cache:put service puts the element in the cache. If the element with the specified key already exists in the cache, pub.cache:put updates the element with the specified value.
If you run pub.cache:put on a disabled cache, the cache discards the call.
Integration Server issues a ServiceException in the following cases:
*If you do not specify all required input parameters.
*If useWriter is set to true and no writer is configured for the cache.
*If Integration Server cannot find the specified cache manager or cache.
*If a cache operation fails.