Historical Monitoring Using Workflow Metrics
The WF Instance History section displays historical metrics for tracked .NET Framework 4 WF service instances managed by AppFabric. The Activations, Failures, and Completions summary metrics provide a summary of successful and failed WF tasks. Expanding the WF Instance History section (by clicking the down arrow or anywhere except the summary metric links within the WF Instance History title bar) displays a summary of the top five services with Instance Activations or Instances with Failures. It also displays Instances with Failures - Grouped by Outcome. You can use these top-level summary values, and their descending correlated detailed views, to monitor the history of tracked WF service instances.
WF Instance History Metrics
The WF Instance History section on the Monitoring Dashboard provides a summary view of WF instance history in the shaded header box where the title WF Instance History exists. The following metrics give you a quick outline view of WF instances that activated successfully and those that did not:
The Activations summary metric is a cumulative total of the WF instances that were activated within the specified time period and may or may not have completed.
The Failures summary metric is a cumulative total of the number of workflow instances that experienced one or more failures (regardless of activation time) within the specified time period.
The Completions summary metric is a cumulative total of the number of WF instances that completed (regardless of activation time) within the specified time period.
Below the summary metrics are the following service metrics that summarize the number of workflow service instances within specific instance categories:
Instance Activations - Grouped by Service (top 5) - The top five services with the highest total number of workflow instance activations within the specified time period.
Instances with Failures - Grouped by Service (top 5) - The top five services with the highest total number of workflow instances that experienced failures within the specified time period.
Instances with Failures - Grouped by Outcome - Based on the Failures summary metric, this metric contains a breakdown of the number of workflow instances that have been recovered (Resumed) instead of currently not recovered. Only durable Workflow Services with persistence enabled are recoverable.
Tracked WF Instances Page
You can use the Tracked WF Instances page to view historical data and status information related to workflow instances that have run with monitoring (tracking) enabled. Clicking any of the summary metrics (say Activations), or one of the service links under a column in the WF Instance History section (say under the Instance Activations Grouped by Service (top 5) column), takes you to the Tracked WF Instances page.
The link that you click to take you from the Dashboard page to the Tracked WF Instances page is used to filter the tracked workflow instance data so that what is enumerated on the Tracked WF Instances page is specific to that originating link. For example, clicking a service entry link under the Instance Activations column takes you to the Tracked WF Instances page to enumerate filtered workflow instances for that service type with a Creation Time within the time period used in the original query.
You can, however, change the value of one or more fields (say Creation Time) within the Query Summary frame to change the initial output and do further troubleshooting on a specific workflow instance. For example, if the original creation time that took you to the Tracked WF Instances page was Sunday, September 20, 2009, 10:30:43 AM, you could change the value of the Creation Time field to Tuesday, September 22, 2009, 10:30:43 AM, and then click Run Query to see different results.
For more information, see Tracked WF Instances Page.
Troubleshooting by Monitoring WF Instance History Metrics
You can assemble the preceding information into a troubleshooting approach by using the WF Instance History section to monitor tracked workflow instances. When you initially view the WF Instance History section, you get a high-level summary of workflow instance execution. You can quickly see if there is a problem in the activation or execution of tracked workflows. If the Instances with Failures - Grouped by Service (top 5) summary metric contains a non-zero value, it indicates where a problem may have occurred. The Instances with Failures - Grouped by Outcome can be used to understand how many of the workflow instances that experienced a failure have not been recovered, and may need actionable attention (for durable workflow services). Each summary metric is linked to the Tracked WF Instances page, where you can see explicit detailed metrics of tracked workflow instance data that the initial Dashboard page summarized for you at the higher level. This breakdown gives you additional information to isolate a problem surrounding tracked WF instances. The first level of drill-down on the Tracked WF Instances page displays all tracked workflow instance entries filtered by conditions. You can drill down again into each tracked WF instance entry by using the Tracked Events page.
Let’s take a scenario where you are using the WF Instance History section to monitor WF services at a given scope to see if there have been any problems. If you see the Failures summary metric as non-zero, then expanding the section will allow you to see a breakdown of the failures by the top five services. This allows you to focus on the services with the greatest number of potential issues. You can then touch on a specific problem service and specify details by going to the enumeration page and changing the query values.
Suppose the Failures summary header displays a non-zero value to show that some workflow instances experienced failures. You can expand the WF Instance History widget and look under the Instances with Failures - Grouped by Service (top 5) column to see the top five services that experienced failures during the selected time period. To gain more details on the failures, you can click one of the service links to take you to the Tracked Events page.
|If you are looking for failure data on a particular service that is not shown in the top five services, you can click the Failures summary column to take you to the Tracked WF Instances page. After you are on that page, you can modify the existing query accordingly. For instance, you can add the service to the scope condition.|
Suppose the Failures summary header displays a non-zero value to show that some activation failures occurred. You can expand the WF Instance History section and look under the Instances with Failures - Grouped by Service (top 5) column to see the top five services that failed activation during the selected time period. If workflow Service X is one of the top five failed workflows, its service link will be displayed here. Clicking its service link takes you to the Tracked Events page. If Service X is not one of the top five services, you can click the Failures summary column to take you to the Tracked WF Instances page, and then locate Service X in the Service Name query results column. Alternatively, you can select Service X from the Scope field and run the query to locate only instances from that service.
The WF Instance History page is populated with a historical view of the tracked WF instances at the specific scope in the IIS hierarchy for Service X. You can click one of these workflows in the middle pane (still within the Tracked WF Instances page) to display specifics of that workflow in the Details pane at the bottom of the page. Within the Details pane you can view information about the workflow on the Overview tab. This tab contains information about the tracked workflow instance, such as the Service Virtual Path, its Workflow Instance ID, number of Tracked Events for its lifetime, Creation Time, and other information. You can use this information to better understand the lifetime of a tracked workflow instance
|Because the Tracked WF Instances page displays historical data on workflow instances, instance control operations are not supported from this page. Instance control operations can only be issued from the Persisted WF Instances Page. A tracked WF instance does not directly correlate to a persisted WF instance because you can enable tracking (monitoring) and persistence independent of each other.|
If you need additional context about a tracked instance you can right-click the instance in the middle pane and then click View Tracked Events. This takes you to the Tracked Events page and displays information for that workflow instance ID. You can also select from the context menu to View Persisted Instance for a workflow instance. To harness the value of the View Persisted Instance option, the application containing the tracked WF service instance must be configured to use persistence and have tracking enabled.
|If the workflow has completed, you may or may not see entries in the persisted WF instance page, depending on whether you have configured your persistence store to retain completed instances. This occurs if your service is configured with persistence enabled.|
Alternatively you can look at the Instances with Failures - Grouped by Outcome column and view the number of tracked instances that are either Recovered or Not Recovered. Clicking the link for either of these also takes you to the Tracked WF Instances page. Depending on the link you clicked, you will see an enumerated list of workflow instances that have either an Aborted status (Not Recovered) or any status other than Aborted (Recovered), respectively. As described above, selecting one of the tracked workflow instances in the enumerated list yields additional information in the Details pane. You can also right-click and select either the View Tracked Events or View Persisted Instance option if applicable.