Skip to content

Commit 9b965db

Browse files
authored
Merge pull request #204246 from xujxu/update-job-diagram-doc
Update job diagram doc
2 parents 0dfc60c + d6fdba7 commit 9b965db

9 files changed

+90
-6
lines changed

articles/stream-analytics/TOC.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -393,8 +393,8 @@
393393
href: app-insights-export-stream-analytics.md
394394
- name: Export to SQL using Stream Analytics
395395
href: app-insights-export-sql-stream-analytics.md
396-
- name: Debug using job diagram
397-
href: stream-analytics-job-diagram-with-metrics.md
396+
- name: Debug using job diagram (preview)
397+
href: stream-analytics-job-diagram-with-metrics-new.md
398398
- name: Scale with ML functions
399399
href: stream-analytics-scale-with-machine-learning-functions.md
400400
- name: Stream Analytics Query Language

articles/stream-analytics/debug-locally-using-job-diagram-vs-code.md

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ Streaming jobs that output no result or unexpected results often need troublesho
1515

1616
## Debug a query using job diagram
1717

18-
An Azure Stream Analytics script is used to transform input data to output data. The job diagram shows how data flows from input sources, like Event Hub or IoT Hub, through multiple query steps to output sinks. Each query step is mapped to a temporary result set defined in the script using a `WITH` statement. You can view the data as well as metrics of each query step in each intermediate result set to find the source of an issue.
18+
An Azure Stream Analytics script is used to transform input data to output data. The job diagram shows how data flows from input sources, like Event Hubs or IoT Hub, through multiple query steps to output sinks. Each query step is mapped to a temporary result set defined in the script using a `WITH` statement. You can view the data as well as metrics of each query step in each intermediate result set to find the source of an issue.
1919

2020
> [!NOTE]
2121
> This job diagram only shows the data and metrics for local testing in a single node. It should not be used for performance tuning and troubleshooting.
@@ -93,11 +93,9 @@ Select **Job Summary** at the top-right of the job diagram to see properties and
9393
9494
## Limitations
9595

96-
* Live output sinks aren't supported in local run.
97-
9896
* Run job locally with JavaScript function is only supported on the Windows operating system.
9997

100-
* C# custom code and Azure Machine Learning functions aren't supported.
98+
* Azure Machine Learning functions aren't supported.
10199

102100
* Only cloud input options have [time policies](./stream-analytics-time-handling.md) support, while local input options don't.
103101

Loading
219 KB
Loading
Loading
Loading
Loading
Loading
Lines changed: 86 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,86 @@
1+
---
2+
title: Debugging with the job diagram (preview) in Azure portal
3+
description: This article describes how to troubleshoot your Azure Stream Analytics job with job diagram and metrics in the Azure portal.
4+
titleSuffix: Azure Stream Analytics
5+
author: xujiang1
6+
ms.author: xujiang1
7+
ms.service: stream-analytics
8+
ms.topic: how-to
9+
ms.date: 07/01/2022
10+
---
11+
12+
# Debugging with the job diagram (preview) in Azure portal
13+
14+
The job diagram in the Azure portal can help you visualize your job's query steps with its input source, output destination, and metrics. You can use the job diagram to examine the metrics for each step and quickly identify the source of a problem when you troubleshoot issues.
15+
16+
The job diagram is also available in Stream Analytics extension for VS Code. It provides the similar functions with more metrics when you debug your job that runs locally on your device. To learn more details, see [Debug Azure Stream Analytics queries locally using job diagram](./debug-locally-using-job-diagram-vs-code.md).
17+
18+
## Using the job diagram
19+
20+
In the Azure portal, while in a Stream Analytics job, under **Support + troubleshooting**, select **Job diagram (preview)**:
21+
22+
:::image type="content" source="./media/stream-analytics-job-diagram-with-metrics-new/1-stream-analytics-job-diagram-with-metrics-portal.png" alt-text="Screenshot that shows job diagram with metrics - location.":::
23+
24+
25+
The job level default metrics such as Watermark delay, Input events, Output Events, and Backlogged Input Events are shown in the chart section for the latest 30 minutes. You can visualize other metrics in a chart by selecting them in the left pane.
26+
27+
:::image type="content" source="./media/stream-analytics-job-diagram-with-metrics-new/2-job-logical-diagram-overview.png" alt-text="Screenshot that shows job logical diagram overview." lightbox="./media/stream-analytics-job-diagram-with-metrics-new/2-job-logical-diagram-overview.png":::
28+
29+
If you select one of the nodes in diagram section, the metrics data and the metrics options in the chart section will be filtered according to the selected node's properties. For example, if you select the input node, only the input node related metrics and its options are shown:
30+
31+
:::image type="content" source="./media/stream-analytics-job-diagram-with-metrics-new/3-job-logical-diagram-node-selection.png" alt-text="Screenshot that shows job logical diagram node selection." lightbox="./media/stream-analytics-job-diagram-with-metrics-new/3-job-logical-diagram-node-selection.png":::
32+
33+
To see the query script snippet that is mapping the corresponding query step, click the **'{}'** in the query step node as below:
34+
35+
:::image type="content" source="./media/stream-analytics-job-diagram-with-metrics-new/4-job-logical-diagram-query-step-mapping-to-script.png" alt-text="Screenshot that shows job logical diagram query step mapping to script.":::
36+
37+
To see the job overview information summary, click the **Job Summary** button in right side.
38+
39+
:::image type="content" source="./media/stream-analytics-job-diagram-with-metrics-new/5-job-logical-diagram-job-summary.png" alt-text="Screenshot that shows job logical diagram job summary." lightbox="./media/stream-analytics-job-diagram-with-metrics-new/5-job-logical-diagram-job-summary.png":::
40+
41+
It also provides the job operation actions in the menu section. You can use them to stop the job (**Stop** button), refresh the metrics data (**Refresh** button), and change the metrics time range (**Time range**).
42+
43+
:::image type="content" source="./media/stream-analytics-job-diagram-with-metrics-new/6-job-logical-diagram-control-menu.png" alt-text="Screenshot that shows job logical diagram control menu." lightbox="./media/stream-analytics-job-diagram-with-metrics-new/6-job-logical-diagram-control-menu.png":::
44+
45+
## Troubleshoot with metrics
46+
47+
A job's metrics provides lots of insights to your job's health. You can view these metrics through the job diagram in its chart section in job level or in the step level. To learn about Stream Analytics job metrics definition, see [Azure Stream Analytics job metrics](./stream-analytics-job-metrics.md). Job diagram integrates these metrics into the query steps (diagram). You can use these metrics within steps to monitor and analyze your job.
48+
49+
### Is the job running well with its computation resource?
50+
51+
* **SU (Memory) % utilization** is the percentage of memory utilized by your job. If SU (Memory) % utilization is consistently over 80%, it shows the job is approaching to the maximum allocated memory.
52+
* **CPU % utilization** is the percentage of CPU utilized by your job. There might be spikes intermittently for this metric. Thus, we often check its average percentage data. High CPU utilization indicates that there might be CPU bottleneck if the number of backlogged input events or watermark delay increases at the same time.
53+
54+
55+
### How much data is being read?
56+
57+
The input data related metrics can be viewed under **Input** category in the chart section. They're available in the step of the input.
58+
* **Input events** is the number of data events read.
59+
* **Input events bytes** is the number of event bytes read. This can be used to validate that events are being sent to the input source.
60+
* **Input source received** is the number of messages read by the job.
61+
62+
### Are there any errors in data processing?
63+
64+
* **Deserialization errors** is the number of input events that couldn't be deserialized.
65+
* **Data conversion errors** is the number of output events that couldn't be converted to the expected output schema.
66+
* **Runtime errors** is the total number of errors related to query processing (excluding errors found while ingesting events or outputting results).
67+
68+
### Are there any events out of order that are being dropped or adjusted?
69+
70+
* **Out of order events** is the number of events received out of order that were either dropped or given an adjusted timestamp, based on the Event Ordering Policy. This can be impacted by the configuration of the **"Out of order events"** setting under **Event ordering** section in Azure portal.
71+
72+
### Is the job falling behind in processing input data streams?
73+
74+
* **Backlogged input events** tells you how many more messages from the input need to be processed. When this number is consistently greater than 0, it means your job can't process the data as fast as it's coming in. In this case you may need to increase the number of Streaming Units and/or make sure your job can be parallelized. You can see more info on this in the [query parallelization page](./stream-analytics-parallelization.md).
75+
76+
77+
## Get help
78+
For more assistance, try our [Microsoft Q&A question page for Azure Stream Analytics](/answers/topics/azure-stream-analytics.html).
79+
80+
## Next steps
81+
* [Introduction to Stream Analytics](stream-analytics-introduction.md)
82+
* [Get started with Stream Analytics](stream-analytics-real-time-fraud-detection.md)
83+
* [Azure Stream Analytics job metrics](./stream-analytics-job-metrics.md)
84+
* [Scale Stream Analytics jobs](stream-analytics-scale-jobs.md)
85+
* [Stream Analytics query language reference](/stream-analytics-query/stream-analytics-query-language-reference)
86+
* [Stream Analytics management REST API reference](/rest/api/streamanalytics/)

0 commit comments

Comments
 (0)