Repository navigation
Expand file tree
/
Copy pathExceptions.workbook
More file actions
281 lines (281 loc) · 11.6 KB
/
Copy pathExceptions.workbook
File metadata and controls
281 lines (281 loc) · 11.6 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
{
"$schema": "https://github.com/Microsoft/Application-Insights-Workbooks/blob/master/schema/workbook.json",
"version": "Notebook/1.0",
"isLocked": true,
"items": [
{
"type": 1,
"content": {
"json": "# Troubleshooting Exceptions\nThis troubleshooting guide helps you analyze your application's exceptions."
},
"conditionalVisibility": null,
"halfWidth": false
},
{
"type": 9,
"content": {
"version": "KqlParameterItem/1.0",
"query": "",
"crossComponentResources": [],
"parameters": [
{
"id": "eac9cbf1-6364-4f28-9c61-a9b038c035d7",
"version": "KqlParameterItem/1.0",
"name": "TimeRange",
"type": 4,
"description": null,
"isRequired": true,
"isHiddenWhenLocked": false,
"typeSettings": {
"selectableValues": [
{
"durationMs": 300000,
"createdTime": "2018-06-04T19:27:14.510Z",
"isInitialTime": false,
"grain": 1,
"useDashboardTimeRange": false
},
{
"durationMs": 900000,
"createdTime": "2018-06-04T19:27:14.510Z",
"isInitialTime": false,
"grain": 1,
"useDashboardTimeRange": false
},
{
"durationMs": 1800000,
"createdTime": "2018-06-04T19:27:14.510Z",
"isInitialTime": false,
"grain": 1,
"useDashboardTimeRange": false
},
{
"durationMs": 3600000,
"createdTime": "2018-06-04T19:27:14.510Z",
"isInitialTime": false,
"grain": 1,
"useDashboardTimeRange": false
},
{
"durationMs": 14400000,
"createdTime": "2018-06-04T19:27:14.510Z",
"isInitialTime": false,
"grain": 1,
"useDashboardTimeRange": false
},
{
"durationMs": 43200000,
"createdTime": "2018-06-04T19:27:14.510Z",
"isInitialTime": false,
"grain": 1,
"useDashboardTimeRange": false
},
{
"durationMs": 86400000,
"createdTime": "2018-06-04T19:27:14.511Z",
"isInitialTime": false,
"grain": 1,
"useDashboardTimeRange": false
},
{
"durationMs": 172800000,
"createdTime": "2018-06-04T19:27:14.511Z",
"isInitialTime": false,
"grain": 1,
"useDashboardTimeRange": false
},
{
"durationMs": 259200000,
"createdTime": "2018-06-04T19:27:14.511Z",
"isInitialTime": false,
"grain": 1,
"useDashboardTimeRange": false
},
{
"durationMs": 604800000,
"createdTime": "2018-06-04T19:27:14.511Z",
"isInitialTime": false,
"grain": 1,
"useDashboardTimeRange": false
},
{
"durationMs": 1209600000,
"createdTime": "2018-06-04T19:27:14.511Z",
"isInitialTime": false,
"grain": 1,
"useDashboardTimeRange": false
},
{
"durationMs": 2419200000,
"createdTime": "2018-06-04T19:27:14.511Z",
"isInitialTime": false,
"grain": 1,
"useDashboardTimeRange": false
}
],
"allowCustom": false
},
"value": {
"durationMs": 86400000,
"createdTime": "2018-06-04T19:27:14.511Z",
"isInitialTime": false,
"grain": 1,
"useDashboardTimeRange": false
}
},
{
"id": "6ab5c1cb-bad0-4d96-8e63-d439d0681c6e",
"version": "KqlParameterItem/1.0",
"name": "Problems",
"type": 2,
"description": null,
"isRequired": true,
"multiSelect": true,
"quote": "'",
"delimiter": ",",
"query": "exceptions\n| where timestamp {TimeRange}\n| summarize by problemId\n| order by problemId asc\n| project v = problemId, t = problemId, s=false\n| union (datatable(v:string, t:string, s:boolean)[\n'*', 'All Problems', true\n])",
"isHiddenWhenLocked": false,
"resourceType": "microsoft.insights/components"
},
{
"id": "84caf619-7585-48e0-a9c3-85c364aaa13b",
"version": "KqlParameterItem/1.0",
"name": "Show",
"type": 2,
"description": null,
"isRequired": true,
"multiSelect": null,
"query": "datatable(x:string, y:string)[\r\n\"['New Failure Rate (%)'], ['Existing Failure Rate (%)']\", 'New and Existing Problems',\r\n\"['New Failure Rate (%)']\", 'Only New Problems',\r\n\"['Existing Failure Rate (%)']\", 'Only Existing Problems',\r\n]",
"value": "['New Failure Rate (%)'], ['Existing Failure Rate (%)']"
},
{
"id": "6f0de137-0136-48f0-b463-640de7109c05",
"version": "KqlParameterItem/1.0",
"name": "UseComparisonTimeRangeOf",
"type": 1,
"description": null,
"isRequired": true,
"query": "let t = todatetime({TimeRange:end}) - todatetime({TimeRange:start});\r\nlet w = case(t <= 1d, '7d', t <= 3d, '14d', t <= 14d, '28d', '60d');\r\nrange i from 1 to 1 step 1\r\n| project x = w",
"isHiddenWhenLocked": false,
"resourceType": "microsoft.insights/components",
"value": "14d"
}
],
"resourceType": "microsoft.insights/components"
},
"conditionalVisibility": null,
"halfWidth": false
},
{
"type": 1,
"content": {
"json": "Set the parameters above to tune your analysis set. Use the `Show` parameter above to see only existing or new failures. The comparision `UseComparisionTimeRange` parameter sets the window of time to look for existing failures. A `Problem` just a combination of exception type and method at which it is thrown. Changing this parameter allows you filter down to a smaller set of issues."
},
"conditionalVisibility": null,
"halfWidth": false
},
{
"type": 1,
"content": {
"json": "## Exception Trend\nThe chart below shows the trend of exceptions over your chosen time range. It is split by new and existing exceptions. "
},
"conditionalVisibility": null,
"halfWidth": false
},
{
"type": 3,
"content": {
"version": "KqlItem/1.0",
"query": "let bigWindow = exceptions\r\n| where timestamp >= {TimeRange:start} - {UseComparisonTimeRangeOf} and timestamp <= {TimeRange:start}\r\n| where problemId in ({Problems}) or '*' in ({Problems})\r\n| summarize makelist(problemId, 100000);\r\nlet data = exceptions\r\n| where timestamp {TimeRange}\r\n| where problemId in ({Problems}) or '*' in ({Problems});\r\ndata\r\n| extend IsNew = problemId !in (bigWindow)\r\n| where \"{Show}\" == \"['New Failure Rate (%)'], ['Existing Failure Rate (%)']\" or IsNew == true\r\n| make-series Count = count() default = 0 on timestamp in range({TimeRange:start}, now(), {TimeRange:grain}) by ['Failure'] = iff(IsNew, 'New Failure', 'Existing Failure')\r\n\r\n",
"showQuery": false,
"size": 0,
"aggregation": 0,
"showAnnotations": false,
"showAnalytics": false,
"resourceType": "microsoft.insights/components",
"visualization": "barchart"
},
"conditionalVisibility": null,
"halfWidth": false
},
{
"type": 1,
"content": {
"json": "## Exception Details"
},
"conditionalVisibility": null,
"halfWidth": false
},
{
"type": 1,
"content": {
"json": "\n🔸 New Failure 🔹 Existing Failure"
},
"conditionalVisibility": null,
"halfWidth": false
},
{
"type": 3,
"content": {
"version": "KqlItem/1.0",
"query": "let bigWindow = exceptions\n| where timestamp >= {TimeRange:start} - {UseComparisonTimeRangeOf} and timestamp <= {TimeRange:start}\n| where problemId in ({Problems}) or '*' in ({Problems})\n| summarize makelist(problemId, 100000);\nlet data = exceptions\n| where timestamp {TimeRange}\n| where problemId in ({Problems}) or '*' in ({Problems});\ndata\n| extend IsNew = problemId !in (bigWindow)\n| where \"{Show}\" == \"['New Failure Rate (%)'], ['Existing Failure Rate (%)']\" or IsNew == true\n| summarize Count = count(), Users = dcount(user_Id) by problemId, IsNew\n| join kind=inner (data\n | make-series Trend = count() default = 0 on timestamp in range({TimeRange:start}, now(), {TimeRange:grain}) by problemId\n | project problemId, Trend\n ) on problemId\n| order by Users desc, Count desc, problemId asc\n| project ['Problem'] = iff(IsNew, strcat('🔸 ', problemId), strcat('🔹 ', problemId)), ['Exceptions'] = Count, ['Users Affected'] = Users, ['Trend'] = Trend\n",
"showQuery": false,
"size": 0,
"aggregation": 2,
"showAnnotations": false,
"showAnalytics": false,
"resourceType": "microsoft.insights/components",
"visualization": "table",
"gridSettings": {
"formatters": [
{
"columnMatch": "Exceptions",
"formatter": 4,
"formatOptions": {
"min": 0,
"max": null,
"palette": "blue"
}
},
{
"columnMatch": "Users Affected",
"formatter": 4,
"formatOptions": {
"min": 0,
"max": null,
"palette": "blue"
}
},
{
"columnMatch": "Trend",
"formatter": 9,
"formatOptions": {
"min": 0,
"max": null,
"palette": "greenRed"
}
}
]
}
},
"conditionalVisibility": null,
"halfWidth": false
},
{
"type": 1,
"content": {
"json": "## Mitigation\nUse this section to list out the recovery steps for known issues. This allows sharing of information with future issue investigators. "
},
"conditionalVisibility": null,
"halfWidth": false
},
{
"type": 1,
"content": {
"json": "## Customizing your Troubleshooting Guide\n```\n1. Start editing this TSG by clicking on the 'Edit' button on the toolbar on top. \n2. Use the edit buttons on bottom-right of markdown control to update it's contents. \n3. Update the parameters to tune your analysis set.\n4. You can also update the underlying query or grid properties to personalize the analysis/view.\n5. If you want to have two sections for different performance counters, use the clone button at the bottom toolbar of a control. Use the ↑ or ↓ buttons to move the controls up or down.\n```\n"
},
"conditionalVisibility": null,
"halfWidth": false
}
]
}