Regenerate Cache APIs
A set of three REST APIs is available to regenerate the API cache. This section describes each of the regenerate cache APIs.
Before you begin the regenerate cache job, prepare and initialize the CPQ API cache.
You must invoke all of them in the correct order, with one conditional exception.
API Name | Description |
---|---|
Defines all offer and availability changes applicable to your catalogs, including changes that impact eligibility or effectivity. Examples include offer or bundle modifications such as changes in description, attachments, and cardinality. | |
Derives the scope of the impacted cache records from the CachedAPIChangeIds passed from the previous API to this API's request body. | |
Gets the cached records affected by the cachedAPIChange objects derived from the CachedAPIChangeIds passed from the previous API to this API's request body as a post method. There are up to 3 different API calls provided by the action nodes of this API's response. They are invalidateAction, generateAction, and regenerateAction. They must be executed with the invalidateAction calls first, followed by the generateAction calls, and finally the regenerateAction calls. In some cases, you will not need to perform generateAction calls, and you will not receive a corresponding node. The cachedAPIChangeIds received from the previous API should be provided in the request body for this API. This API gets the cached records that will be affected by the derived cachedAPIChange objects.
|
Before you begin using these APIs, complete the following steps, and complete steps 1 to 3 before you make any catalog changes.
-
Enable Cache Management in your Custom Settings:
-
From Setup, in the Quick Find box, enter
Custom Settings
. -
Click Custom Settings.
-
Go to Trigger Setup.
-
Next to Trigger Setup, click Manage. The Trigger Setup page appears.
-
Click Edit beside CacheAPI.CacheManagement, and turn on the trigger.
If you do not see a trigger for CacheAPI.CacheManagement:
-
Click New.
-
Enter
CacheAPI.CacheManagement
in the Name field. -
Click Trigger On.
-
Click Save.
-
-
-
Set the following CPQ Configuration Custom Settings:
-
Click the App Launcher.
-
Click Vlocity CMT Administration.
-
Under Custom Settings, click CPQ Configuration Setup.
-
Create the
CacheAPI.RegenerateBatchCacheProcessor
setting and set its value toTrue
:
-
-
Ensure the following picklist values are added to their appropriate object fields specified here:
-
CachedAPIChange: vlocity_cmtChangeTypec
-
CachedAPIChange: vlocity_cmtCodeTypec
-
-
Run the following Maintenance Jobs from Vlocity CMT Administration:
-
Perform these additional requirements for using the Regenerate Cache APIs:
-
Run the maintenance jobs listed in step 4 anytime you must execute the Regenerate Cache APIs.
-
Populate the API cache using the populate cache APIs. Do not use the Vlocity CMT Administration Cacheable API Jobs (batch APEX) while using the cache management APIs. Use either the batch APEX jobs or the cache management APIs, not both.
-
Execute all of the regenerate cache APIs in the chronological order presented.
-
Ensure you do not modify your catalog or product offerings until you have executed all of the regenerate cache APIs.
-