- 18 Oct 2021
- 2 Minutes to read
- Print
- DarkLight
Outcome Caching
- Updated on 18 Oct 2021
- 2 Minutes to read
- Print
- DarkLight
Overview
In contrast to Bespoke Caching via Flow steps, Outcome Caching is a type of Caching that allows users to Cache information on the Output/Outcome of a step. Rather than creating a Cache copy for more long-term use, Outcome Cache can be set to hold onto Cached data for a set period of Time.
Due to its nature, Outcome Caching is particularly useful for users that may need to quickly fetch information for their respective customers or can be used to make easily accessible copies of Flow Data pertaining to a specific step.
Example
To Cache the Outcome of a step:
The Fetch Entities step is used as it includes built-in Caching. An example use utilizing this step may involve utilizing Table Integegration or Token Authentication.
- From a Designer Folder, select CREATE. Then, CREATE a new Flow.
- From the Flow Designer, attach a Fetch Entities step from Steps > Favorite Steps to the Start step. Then connect both the Results and No Results paths to the End step.
- From the Properties tab of the Fetch Entities step, under Entity Fetch Definition > Type Name, search for and select Account.
- Still in the Properties tab, navigate to and expand the Outcomes category. Then, select the desired setting from the Cache Outcomes dropdown (for this example, PerUser). Additional Information on Cache OutcomesThe Cache Outcomes setting allows users to select one of the following options:
- None: Leaves the Outcome Caching setting turned off.
- Global: Caches Outcome data for all Accounts on the Decisions environment.
- Per User: Only Caches Outcome data for the user that executes the step.
From the same Outcomes category, establish a Cache Timespan by inputting the desired values into each box, or adjusting the value via the slider.
Additional InformationThe Cache Timespan setting is used to determine how long the Outcome data remains within the Cache.Save the Flow, then if desired close the Flow Designer via X.
Debug
- From the Flow Designer, select the Debug link from the top Action Bar.
- Click START DEBUGGING.
- After the Flow runs, select Fetch Entities > Execution 1 > View Output Data. Debug ResultsThe resulting Output Data will remain cached for 5 minutes.
Outcome Caching Limitations
Due to the nature of Caching the Outcome of a step, information that is cached from steps cannot be fetched via a Get From Cache step. As a result, this cached data cannot be used outside of the Flow for further evaluation or retrieval purposes, and can only exist for the set Cache Timespan.
To accommodate this need, users may use a Cache Definition in conjunction with additional Caching steps to add the data to a Cache that can be used outside of the origin Flow.