Flow execution settings
Summarize
Summary of Flow execution settings
Flow execution settings in ServiceNow allow you to specify runtime configurations for individual flows, subflows, or actions. These settings include run priority, reporting level, and logging level, enabling detailed execution data collection tailored to specific items. Execution setting records override system-wide reporting properties and apply whenever the related flow, subflow, or action runs directly.
Show less
Key Features
- Execution Setting Records: Create multiple records for different flows, subflows, or actions to selectively collect execution details.
- Report All Iterations: Optionally gather execution details for all loop iterations instead of only the first and last, useful when flows pause between iterations.
- Reporting and Logging Levels: Control the granularity of execution detail collection and logging messages in the Flow engine log entries table.
- Flow Priority: Set priority for background flow execution, with options to reveal this field if hidden.
- Inheritance: Actions or subflows invoked from a parent flow use the parent’s execution settings.
Best Practices for ServiceNow Customers
- Avoid Production Impact: Enable execution reporting primarily on non-production instances to prevent performance degradation.
- Test Thoroughly: Generate execution details during testing at debug level to validate flows before deploying to production.
- Manage Memory Usage: Limit reporting on all loop iterations to reduce memory consumption.
- Use Reporting for Troubleshooting Only: Activate detailed execution reporting and iteration logging only when diagnosing flow issues, and disable or delete records after troubleshooting to preserve instance resources.
Practical Use
ServiceNow customers can leverage flow execution settings to gain granular insights into flow performance and behavior during development and testing phases. By configuring these settings strategically, you can troubleshoot effectively without impacting production system performance. This enables better flow optimization and reliability before deployment.
Specify the runtime settings for an individual flow, subflow, or action such as the run priority, reporting level, and logging level.
You can create an execution settings record for each flow, subflow, or action for which you want to collect execution details. An execution setting record [sys_flow_execution_setting] overrides the reporting system properties for a particular item. For example, you can keep the system wide reporting level off, and create execution setting records just for the items that you want to collect execution details.
Execution setting records are available from the Flow administration module.
Execution setting record fields
An execution setting record [sys_flow_execution_setting] contains these fields.
| Field | Description |
|---|---|
| Flow/SubFlow/Action | Individual flow, subflow, or action to which the execution settings apply. |
| Report all iterations | Option to gather execution details for all iterations of a loop that have run rather than just storing execution details for the first and last run iterations. If a flow pauses between iterations, then the execution details include all iterations that have run. When this option is false, the execution details only include the first and last iterations run. |
| Reporting | Reporting level at which to gather execution details. |
| Logging | Logging level threshold required for Workflow Studio to write a message generated by the flow engine to the Flow engine log entries [sys_flow_log] table. |
| Flow Priority | Priority value used to run a background flow. For more information about setting flow priority, see Flow priority. Note: .This field is hidden by default. For more information about showing the flow priority field, see Show flow priority field. |
General guidelines
Use these general guidelines when creating execution setting records to capture execution details.
- Avoid reporting on production instances
- Avoid performance issues on your production instance by only activating and configuring reporting on a non-production instance that you use for testing. Generating and storing execution details consumes instance resources, which can lower performance.
- Create execution setting records on a non-production test instance
- Create execution setting records on a non-production testing instance to minimize the performance impact of generating and storing execution details.
- Reduce the amount of memory consumed by flow loops
- Reduce the amount of memory consumed by generating execution details by not using the option to report all iterations. The more iterations you report on, the more memory is required.
- Test flows, subflows, and actions to generate execution details
- Test your flows, subflows to generate execution details at the debug level. Only deploy your items to a production instance after you verify that they generate the data you want and that they perform as expected.
- Use flow reporting and the report all iterations options only during flow troubleshooting
- Use the flow reporting and report all iterations options only when you need to troubleshoot a flow. These settings generate information that consume instance resources. To reduce their performance impact, either turn off these settings or delete the settings record altogether when you are done troubleshooting the flow.