Using Debugging StepsLast Updated: 05/02/2018 Introduced in Version: 2.0
When debugging a flow, it is sometimes useful to create debugging steps. These steps can provide information about, or gather data from, a certain step in the flow before the flow has finished running.
Debugging steps can record information in system logs, output the current step’s flow data, output a message, or output a string.
To create a debugging step, drag any one of the Flow Management components under the category Debugging to the Flow Designer workspace. Place it in the path of the step outcome to debug and then, adjust the mapping and component properties to match your debugging requirements.
Add the Collect Log Info form to capture the message to log by expanding the Flow Designer startup window’s Flows, Rules, Forms and Reports > Forms [Interaction] > [Current Folder] category, then selecting a Collect Log Info Form component. Click Add to add it to the workspace.
Expand the Flow Management > Debugging category, and drag a Log component to the workspace.
Connect the outcome paths in the flow. When the flow runs, the Collect Log Info Form opens and captures user-entered data. The Log 1 component logs that data as an error in the system (once it has been configured to do so in the following step).
By default, the Log component does not know which information to capture. Use the Mapping Editor to specify.
Select the Log 1 step, then click the Edit Input Mapping link in the Actions Toolbar.
There is only one input available to monitor – LogInfo. Map that to the Value field and click OK to exit the Mapping Editor.
The Log has several options for customizing what types of logs are sent and how they appear on the report. You can make these customizations by selecting the step Log 1 and, in the Properties > Setup Log and selecting a value from the Type drop-down list. Select Error to ensure that the inputs caught by Log 1 are sent to the same system log as true errors. Also categorize these log entries as Custom in the Category field to make the errors easier to find.
Our debugging step is now complete. Save the flow and run it in the Debugger by clicking the Debug Flow link.
A form collects our input and, with that input, creates an error entry in our systems log.
We can view the flow’s execution.
This debugging step can process information about the error itself, the outcome that preceded it, the user it occurred under and the time when it occurred. All that’s needed is to map and categorize the appropriate inputs into your Log component.
To view the error message, navigate to the folder System > Logging. The message displays under the category we assigned it.