| 1 | # you can disable an alarm notification by setting the 'to' line to: silent |
| 2 | |
| 3 | # ── Resource Utilization ──────────────────────────────────────────────────── |
| 4 | |
| 5 | template: am_stream_analytics_su_utilization |
| 6 | on: azure_monitor.stream_analytics.resource_utilization |
| 7 | class: Utilization |
| 8 | type: Other |
| 9 | component: Azure Stream Analytics |
| 10 | lookup: average -5m unaligned of su_memory |
| 11 | units: percentage |
| 12 | every: 1m |
| 13 | warn: $this > (($status >= $WARNING) ? (75) : (80)) |
| 14 | crit: $this > (($status == $CRITICAL) ? (80) : (90)) |
| 15 | delay: down 5m multiplier 1.5 max 1h |
| 16 | summary: Stream Analytics SU utilization on ${label:resource_name} |
| 17 | info: Average streaming unit (memory) utilization of Stream Analytics job ${label:resource_name} \ |
| 18 | in ${label:resource_group} (${label:region}). \ |
| 19 | Sustained high SU utilization indicates the job needs more streaming units. |
| 20 | to: sysadmin |
| 21 | |
| 22 | template: am_stream_analytics_cpu_utilization |
| 23 | on: azure_monitor.stream_analytics.resource_utilization |
| 24 | class: Utilization |
| 25 | type: Other |
| 26 | component: Azure Stream Analytics |
| 27 | lookup: average -5m unaligned of cpu |
| 28 | units: percentage |
| 29 | every: 1m |
| 30 | warn: $this > (($status >= $WARNING) ? (75) : (80)) |
| 31 | crit: $this > (($status == $CRITICAL) ? (80) : (90)) |
| 32 | delay: down 5m multiplier 1.5 max 1h |
| 33 | summary: Stream Analytics CPU on ${label:resource_name} |
| 34 | info: Average CPU utilization of Stream Analytics job ${label:resource_name} \ |
| 35 | in ${label:resource_group} (${label:region}). \ |
| 36 | High CPU indicates complex query processing or insufficient streaming units. |
| 37 | to: sysadmin |
| 38 | |
| 39 | # ── Watermark Delay ───────────────────────────────────────────────────────── |
| 40 | |
| 41 | template: am_stream_analytics_watermark_delay |
| 42 | on: azure_monitor.stream_analytics.watermark_delay |
| 43 | class: Latency |
| 44 | type: Other |
| 45 | component: Azure Stream Analytics |
| 46 | lookup: average -5m unaligned of delay |
| 47 | units: seconds |
| 48 | every: 1m |
| 49 | warn: $this > (($status >= $WARNING) ? (60) : (120)) |
| 50 | crit: $this > (($status == $CRITICAL) ? (120) : (300)) |
| 51 | delay: down 5m multiplier 1.5 max 1h |
| 52 | summary: Stream Analytics watermark delay on ${label:resource_name} |
| 53 | info: Output watermark delay of Stream Analytics job ${label:resource_name} \ |
| 54 | in ${label:resource_group} (${label:region}). \ |
| 55 | Growing delay means the job is falling behind processing input data. |
| 56 | to: sysadmin |
| 57 | |
| 58 | # ── Errors ────────────────────────────────────────────────────────────────── |
| 59 | |
| 60 | template: am_stream_analytics_runtime_errors |
| 61 | on: azure_monitor.stream_analytics.errors |
| 62 | class: Errors |
| 63 | type: Other |
| 64 | component: Azure Stream Analytics |
| 65 | lookup: average -5m unaligned of runtime |
| 66 | units: errors/s |
| 67 | every: 1m |
| 68 | warn: $this > (($status >= $WARNING) ? (0) : (1)) |
| 69 | delay: down 5m multiplier 1.5 max 1h |
| 70 | summary: Stream Analytics runtime errors on ${label:resource_name} |
| 71 | info: Runtime errors on Stream Analytics job ${label:resource_name} \ |
| 72 | in ${label:resource_group} (${label:region}). \ |
| 73 | Runtime errors indicate issues with query execution or resource constraints. |
| 74 | to: sysadmin |
| 75 | |
| 76 | template: am_stream_analytics_data_conversion_errors |
| 77 | on: azure_monitor.stream_analytics.errors |
| 78 | class: Errors |
| 79 | type: Other |
| 80 | component: Azure Stream Analytics |
| 81 | lookup: average -5m unaligned of data_conversion |
| 82 | units: errors/s |
| 83 | every: 1m |
| 84 | warn: $this > (($status >= $WARNING) ? (0) : (1)) |
| 85 | delay: down 5m multiplier 1.5 max 1h |
| 86 | summary: Stream Analytics conversion errors on ${label:resource_name} |
| 87 | info: Data conversion errors on Stream Analytics job ${label:resource_name} \ |
| 88 | in ${label:resource_group} (${label:region}). \ |
| 89 | These occur when output events cannot be converted to the expected output schema. |
| 90 | to: sysadmin |
| 91 | |
| 92 | template: am_stream_analytics_deserialization_errors |
| 93 | on: azure_monitor.stream_analytics.errors |
| 94 | class: Errors |
| 95 | type: Other |
| 96 | component: Azure Stream Analytics |
| 97 | lookup: average -5m unaligned of deserialization |
| 98 | units: errors/s |
| 99 | every: 1m |
| 100 | warn: $this > (($status >= $WARNING) ? (0) : (1)) |
| 101 | delay: down 5m multiplier 1.5 max 1h |
| 102 | summary: Stream Analytics deserialization errors on ${label:resource_name} |
| 103 | info: Input deserialization errors on Stream Analytics job ${label:resource_name} \ |
| 104 | in ${label:resource_group} (${label:region}). \ |
| 105 | These occur when input events cannot be parsed (malformed JSON, CSV, Avro). |
| 106 | to: sysadmin |
| 107 | |
| 108 | # ── Event Timing ──────────────────────────────────────────────────────────── |
| 109 | |
| 110 | template: am_stream_analytics_out_of_order_events |
| 111 | on: azure_monitor.stream_analytics.event_timing |
| 112 | class: Errors |
| 113 | type: Other |
| 114 | component: Azure Stream Analytics |
| 115 | lookup: average -5m unaligned of out_of_order |
| 116 | units: events/s |
| 117 | every: 1m |
| 118 | warn: $this > (($status >= $WARNING) ? (5) : (10)) |
| 119 | delay: down 5m multiplier 1.5 max 1h |
| 120 | summary: Stream Analytics out-of-order events on ${label:resource_name} |
| 121 | info: Rate of dropped or adjusted out-of-order events on Stream Analytics job \ |
| 122 | ${label:resource_name} in ${label:resource_group} (${label:region}). \ |
| 123 | High rates may indicate clock skew in event sources. |
| 124 | to: sysadmin |
| 125 | |
| 126 | template: am_stream_analytics_late_events |
| 127 | on: azure_monitor.stream_analytics.event_timing |
| 128 | class: Errors |
| 129 | type: Other |
| 130 | component: Azure Stream Analytics |
| 131 | lookup: average -5m unaligned of late |
| 132 | units: events/s |
| 133 | every: 1m |
| 134 | warn: $this > (($status >= $WARNING) ? (5) : (10)) |
| 135 | delay: down 5m multiplier 1.5 max 1h |
| 136 | summary: Stream Analytics late events on ${label:resource_name} |
| 137 | info: Rate of late-arriving input events on Stream Analytics job ${label:resource_name} \ |
| 138 | in ${label:resource_group} (${label:region}). \ |
| 139 | Late events arrive after the late arrival tolerance window. |
| 140 | to: sysadmin |
| 141 | |
| 142 | # ── Backlog ───────────────────────────────────────────────────────────────── |
| 143 | |
| 144 | template: am_stream_analytics_backlogged_events |
| 145 | on: azure_monitor.stream_analytics.backlogged_events |
| 146 | class: Utilization |
| 147 | type: Other |
| 148 | component: Azure Stream Analytics |
| 149 | lookup: average -5m unaligned of backlogged |
| 150 | units: events |
| 151 | every: 1m |
| 152 | warn: $this > (($status >= $WARNING) ? (5000) : (10000)) |
| 153 | crit: $this > (($status == $CRITICAL) ? (10000) : (50000)) |
| 154 | delay: down 5m multiplier 1.5 max 1h |
| 155 | summary: Stream Analytics backlog on ${label:resource_name} |
| 156 | info: Number of backlogged input events on Stream Analytics job ${label:resource_name} \ |
| 157 | in ${label:resource_group} (${label:region}). \ |
| 158 | A growing backlog means the job cannot keep up with the input rate. |
| 159 | to: sysadmin |
| 160 | |
| 161 | # ── Function Requests ─────────────────────────────────────────────────────── |
| 162 | |
| 163 | # Helper: total ML function request rate (used for minimum-data guard) |
| 164 | template: am_stream_analytics_function_request_rate |
| 165 | on: azure_monitor.stream_analytics.function_requests |
| 166 | class: Workload |
| 167 | type: Other |
| 168 | component: Azure Stream Analytics |
| 169 | lookup: average -5m unaligned of total |
| 170 | units: requests/s |
| 171 | every: 1m |
| 172 | summary: Stream Analytics function call rate on ${label:resource_name} |
| 173 | info: Average Azure ML function call rate for Stream Analytics job ${label:resource_name} \ |
| 174 | in ${label:resource_group} (${label:region}) |
| 175 | to: silent |
| 176 | |
| 177 | template: am_stream_analytics_function_failures |
| 178 | on: azure_monitor.stream_analytics.function_requests |
| 179 | class: Errors |
| 180 | type: Other |
| 181 | component: Azure Stream Analytics |
| 182 | lookup: average -5m unaligned of failed |
| 183 | calc: ($am_stream_analytics_function_request_rate > 0) ? ($this * 100 / $am_stream_analytics_function_request_rate) : (0) |
| 184 | units: % |
| 185 | every: 1m |
| 186 | warn: $this != nan AND ($am_stream_analytics_function_request_rate > 0.5) ? ($this > (($status >= $WARNING) ? (5) : (10))) : (0) |
| 187 | crit: $this != nan AND ($am_stream_analytics_function_request_rate > 0.5) ? ($this > (($status == $CRITICAL) ? (15) : (25))) : (0) |
| 188 | delay: down 5m multiplier 1.5 max 1h |
| 189 | summary: Stream Analytics ML function failures on ${label:resource_name} |
| 190 | info: Percentage of failed Azure ML function requests for Stream Analytics job \ |
| 191 | ${label:resource_name} in ${label:resource_group} (${label:region}) |
| 192 | to: sysadmin |