- Updated on 20 Sep 2016
- 5 minutes to read
This tutorial demonstrates Flow Debugging in Decisions 4.0 . The Flow Debugger has been completely redesigned in the HTML version of Decisions .
In this example we are going to build a simple Flow in order to demonstrate Flow Debugging in Decisions 4.0.
We begin in the Designer Folder with clickingCreate Flow on Folder Actions Panel.
In the resulting window we Name the Flow and click OK to proceed to the Flow Designer.
In the Flow Designer workspace, select the Start Step and click the Show Editor linkunder Flow Input Data . This is going to be a String Variable.
Add a Data Definition.
Then, on the Done outcome from the Start Step we add a Capitalize step from All Steps [Catalog] > Data > Text category.
Next, we select the Capitalize step on the workspace. For the Input value we choose Select Value [From Flow] Input data.
On the Done outcome from the Capitalize step we add a Get All step. Integrations > All Integrations > Internal Services > Account Service.
On the Done outcome from the Get All step, we add a Show Popup step from the Favorite Steps category.
Next, we select a Show Popup step on the workspace to setup Step Inputs . We define Constant Subject (Test) and Select Value of Capitalize_Output for Message .
Choose Get All_Output
Finally, we connect the Done outcome from the Show Popup step to the End Step in our Flow . Then, we select the End Step on the workspace and Add New Output Data .
In the resulting window we Name our Output Data and leave its Type String . Click OK to save and close this window.
Next, for the Output Data we Select Value of Capitalize_Output.
This completes our Demo Flow . Next, we are going to overview Flow Designer tools that are helpful in Debugging process. On the left panel of the Flow Designer we click Steps By Type link.
This opens up a Tab with all steps in the Flow sorted by Type . We close this Tab .
Then, we click Steps Explorer link on the left panel of the Flow Designer.
This tool opens up a Tab with all steps in our Flow . This tool is useful to find a step in the Flow when we have too many steps. We close this Tab .
Next, we click Data Explorer link on the left panel of the Flow Designer.
This tool opens up a Tab with all data in our Flow . This tool helps us to track data flow in our Workflow process. For instance, if we click Capitalize_Output String we can see that this Data is created as an outcome from Capitalize step, then used as an Input to Show Popup Step (for Message input) , and used as an Output Data on the End Step in our Flow . Then, we close this Tab .
Next, we click Sample Data link on the left panel of the Flow Designer.
This tool opens up a Tab where we can Add New Unit Tests and Data Samples . We click Add New Unit Test.
In theNew Unit Test pop-up window we define Unit Test Name , create Rule to Evaluate Flow Outcome , and define Flow Input Data . When finished, we click Ok to save Unit Test and continue.
Back in the Sample Data Tab under Unit Tests we can run our Test by clicking the Debug link (play button).
We click Add New link to add Data Sample.
ANew Sample window pops up. In the Sample Data section we define our Flow Input Data . In Sample section we can either Create Sample Type or put this Sample Data under existing category for this Flow . Data Samples are very handy because we can create several Samples and test our Flow execution with different Data . When finished, click Ok to save Sample Data and continue.
Back in the Sample Data Tab, click Debug link (play button) under Data Samples > Test Sample > Test.
Flow Debugger opens. In the main window we can see four Tabs : FLOW, Step Execution (this flow) Page, Step Execution (this flow and sub flows) Page, Debug Report Page , and Execution Dashboard.
TheFLOW Tab demonstrates graphical Flow execution sequence. Currently, our Flow executed successfully. At the bottom of the main window we can see a progress bar with Play button at the end. Also, the green bar at the beginning indicates theStart Step and a red bar at the end indicates End Step.
Select any step on the graphical diagram and click on execution. We can look at the step info, input, and output data. We can look up step information using Show Step Info action.
Step information is being displayed in the pop-up window. Click OK to close Show Step Info pop-up.
By moving the mini circle on the progression bar, at the bottom of the page, we can inspect different Flow Execution States.
Next, we openDebug Report Page Tab in the main Flow Debugger window. This Page contains a Report of all executed Flow Steps . For every step, we have an action to Show Step Info just like we have on graphical Flow execution window. This Page is customizable and can be designed to display additional information using the Decisions Reporting and Dashboard engine.
Finally, we open Execution Dashboard Tab . This is another Page designed using the Decisions Reporting and Dashboard engine. Therefore, it is fully editable. By default it displaysDebug Report along with the following tiles: Total Time, Number of Steps, Number of Flows, Number of Rules, Number of Exceptions . We also have an option to switch from Debug Report to a different Report like:Input Data Report, Output Data Report, Step Executions, etc.