Clear Cache Button for BusComps with a Cache Refresh Key
In this case, you must define a workflow and a run-time event to refresh the cache.
To configure a new Clear Cache button for a business component with a cache refresh key defined
-
Create a control in the desired applet where the Method Invoked is EventMethodCacheRefresh, add the control to the desired applet web template.
-
Define the cache keys by adding user properties to the Row Set Transformation Toolkit business service, according to the format shown in the following table, for example:
Property Value Name
Cache Key: Price List Item
Value
Price List Id
-
Create a workflow that does the following:
-
Calls the Get Cache Key method to determine the selected cache key values.
-
Invokes the Refresh BC On Cache Key method for each business component that shares the same cache key. The following figure shows an example of a Clear Cache workflow.
-
-
Navigate to the Administration - Runtime Events screen, then the Action Sets view, and create a new record in the Action Sets list applet with a name such as “Cache Refresh BC - Applet Name”.
-
Create a new record in the middle list applet, with the following values:
Property Value Name
PSP Refresh
Action Type
BusService
-
In the More Info form applet (at the end), enter the following values:
Property Value Business Service Name
Workflow Process Manager
Business Service Method
RunProcess
Business Service Context
Process Name
For example:
Business Service Context = PSP Refresh Cache On Cache Key - Price List
-
Navigate to the Administration - Runtime Events screen, then the Events view, and create a new record with the following values:
Property Value Object Type
Applet
Object Name
The name of the applet referred to in Step 1
Event
InvokeMethod
Subevent
EventMethodCacheRefresh
Action Set Name
The name of the action set created in Step 4