Checkpoints save the status of the successfully executed actions of your workflow. So that, if the workflow execution fails due to any reason, you can resume workflow execution right from the point it failed. This is especially useful when you are working with complex workflows with several actions.
How to enable checkpoints
Checkpoints work at the workflow level. This means you need to enable checkpoints for each workflow. To do this, follow the steps given below:
Step 1: Navigate to the workflow for which you want to enable checkpoints and click on the ‘Workflow Settings’ icon given at the top-right corner of the canvas.
Step 2: A ‘Workflow Settings’ window will appear on the screen. Select ‘Execution Settings’ from the left-hand side panel and toggle-on the ‘Save status of each successfully executed action’ option.
Once this is done, click ‘Close’. This will enable checkpoints for your workflow.
How checkpoints work
Let’s say, you have a workflow that sends a welcome email to the user via Gmail and posts the basic details of the user on the support team’s space on Cisco Webex Teams, whenever a new user is created in Zendesk, For the purpose of this tutorial, we have entered incorrect space ID in the ‘Cisco Webex Teams’ while configuring the workflow.
Now enable checkpoints for this workflow as explained above and then execute the workflow.
The ‘Cisco Webex Teams - Post New Message’ action will fail and hence the workflow execution will be stopped. You can see the error details in the debug panel.
Make changes to your workflow as per the error details displayed in the debug panel and save it. For our example, we will enter a valid space ID in the ‘Cisco Webex Teams - Post New Message’ action and save the workflow.
Next, click on the ‘Workflow Execution History’ icon given at the bottom-right corner of the window. You will see the list of execution logs associated with the workflow.
Click on the ‘View Log’ button to view the detailed workflow execution logs. In this log, you can see the workflow execution status (failed) and other execution related details, along with the options to ‘Export Log’ and ‘Resume’ workflow. Click on the ‘Resume’ button.
Whenever you make any changes in a workflow, a new workflow version is created. in this case, we are trying to resume the execution of the latest workflow version through the logs of an older version. You will be notified about this change in the dialogue box that appears next. Click ‘Yes’ to proceed.
This will resume the workflow execution.
Note: Resuming a workflow execution starts a new workflow execution cycle, due to which 1 credit—or 2 or 4 credits, depending on your container size—will be deducted from your account.
Once the workflow execution is completed, click on ‘Workflow Execution History’ to check the log data. You will notice that the workflow execution status is changed to ‘Success’.
Click on the ‘View Log’ button to see the detailed log.