Prerequisites to Regenerate Cache
Before you begin the regenerate cache job, prepare and initialize the CPQ API cache.
Follow these steps to use the incremental cache regeneration feature:
-
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.
This ensures you can see catalog changes reflected in the cache after running the Regenerate Cached API Records job.
In the Winter '20 version of the software, there is a known issue with this trigger turnedĀ onĀ that prevents you from importing large datapacks. To work around this issue, import datapacks with a batch size of one. Otherwise, the datapack import (deployment) fails due to excessive SOQL errors violating Salesforce governor limits. We recommend that you do not enable the Digital Commerce cache management trigger unless you are using Vlocity CME patch release Spring '20 107.1.1.
If you do not use the incremental cache regeneration feature with Digital Commerce APIs, or if you want to import datapacks with a batch size larger than one, disable the cache management trigger.
-
-
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 each time changes are made to the product catalog.:
To register only the changes for a new version of the calculation matrix:
-
Turn off the
CacheAPI.CacheManagement
trigger. -
Update the calculation matrix-related data, which requires creating a new version of the calculation matrix.
-
Turn on the
CacheAPI.CacheManagement
trigger. -
Go to All Tabs -> Vlocity Calculation Matrix. Select the currently active matrix from Related list -> Vlocity Calculation Matrix Versions.
-
Under Vlocity Calculation Matrix Version , search for Related Lis -> Vlocity Calculation Matrix Row, which should display all available matrix rows.
-
Search for the row on which the CRUD operation was performed to ensure only the changes get registered.
-
Click Edit and save the record.
-
Run the Clear Managed PlatformCache and Product Hierarchy Maintenance jobs from CMT Administration.
-
Run the Regenerate Batch job.
-