blob: 87ee8223a871a007416d1b059c5eded189c52fd3 [file] [log] [blame]
Basil Eljuse4b14afb2020-09-30 13:07:23 +01001{
2 "annotations": {
3 "list": [
4 {
5 "builtIn": 1,
6 "datasource": "-- Grafana --",
7 "enable": true,
8 "hide": true,
9 "iconColor": "rgba(0, 211, 255, 1)",
10 "name": "Annotations & Alerts",
11 "type": "dashboard"
12 }
13 ]
14 },
15 "editable": true,
16 "gnetId": null,
17 "graphTooltip": 0,
18 "id": 5,
19 "iteration": 1600199355075,
20 "links": [],
21 "panels": [
22 {
23 "content": "<b><center>First table shows the details for the latest tag and the second table shows the details for the selected \"Target Tag\". </b>",
24 "datasource": null,
25 "fieldConfig": {
26 "defaults": {
27 "custom": {}
28 },
29 "overrides": []
30 },
31 "gridPos": {
32 "h": 2,
33 "w": 24,
34 "x": 0,
35 "y": 0
36 },
37 "id": 6,
38 "links": [],
39 "mode": "html",
40 "options": {
41 "content": "<b><center>First table shows the details for the latest tag and the second table shows the details for the selected \"Target Tag\". </b>",
42 "mode": "html"
43 },
44 "pluginVersion": "7.1.0",
45 "title": "Please note that when \"yes\" is selected from the above drop-down, data for both whitelisted and non-whitelisted functions is shown. Currently there are 0 whitelisted functions for TF-A.",
46 "type": "text"
47 },
48 {
49 "aliasColors": {},
50 "bars": true,
51 "dashLength": 10,
52 "dashes": false,
53 "datasource": "TFA_Complexity",
54 "description": "Tracking the number of functions exceeding threshold",
55 "fieldConfig": {
56 "defaults": {
57 "custom": {}
58 },
59 "overrides": []
60 },
61 "fill": 1,
62 "fillGradient": 0,
63 "gridPos": {
64 "h": 9,
65 "w": 24,
66 "x": 0,
67 "y": 2
68 },
69 "hiddenSeries": false,
70 "id": 3,
71 "legend": {
72 "avg": false,
73 "current": false,
74 "max": false,
75 "min": false,
76 "show": false,
77 "total": false,
78 "values": false
79 },
80 "lines": false,
81 "linewidth": 1,
82 "links": [],
83 "nullPointMode": "null",
84 "percentage": false,
85 "pluginVersion": "7.1.3",
86 "pointradius": 5,
87 "points": false,
88 "renderer": "flot",
89 "seriesOverrides": [],
90 "spaceLength": 10,
91 "stack": false,
92 "steppedLine": false,
93 "targets": [
94 {
95 "alias": "$tag_Target_Tag",
96 "dsType": "influxdb",
97 "groupBy": [
98 {
99 "params": [
100 "$__interval"
101 ],
102 "type": "time"
103 },
104 {
105 "params": [
106 "null"
107 ],
108 "type": "fill"
109 }
110 ],
111 "orderByTime": "ASC",
112 "policy": "default",
113 "query": "SELECT max(Functions_Exceeding_Threshold_Not_Whitelisted) FROM \"TFA_Complexity_Tracking\" where ((Whitelisted =~ /^$Whitelisted$/ OR Whitelisted =~ /^no$/) AND $timeFilter) group by Target_Tag, Git_Tag_Date order by time",
114 "rawQuery": true,
115 "refId": "A",
116 "resultFormat": "time_series",
117 "select": [
118 [
119 {
120 "params": [
121 "value"
122 ],
123 "type": "field"
124 },
125 {
126 "params": [],
127 "type": "mean"
128 }
129 ]
130 ],
131 "tags": []
132 }
133 ],
134 "thresholds": [],
135 "timeFrom": null,
136 "timeRegions": [],
137 "timeShift": null,
138 "title": "TFA Complexity Tracking",
139 "tooltip": {
140 "shared": false,
141 "sort": 0,
142 "value_type": "individual"
143 },
144 "type": "graph",
145 "xaxis": {
146 "buckets": null,
147 "mode": "series",
148 "name": null,
149 "show": true,
150 "values": [
151 "max"
152 ]
153 },
154 "yaxes": [
155 {
156 "decimals": 0,
157 "format": "short",
158 "label": "Functions Exceeding Threshold",
159 "logBase": 1,
160 "max": null,
161 "min": null,
162 "show": true
163 },
164 {
165 "format": "short",
166 "label": null,
167 "logBase": 1,
168 "max": null,
169 "min": null,
170 "show": false
171 }
172 ],
173 "yaxis": {
174 "align": false,
175 "alignLevel": null
176 }
177 },
178 {
179 "columns": [],
180 "datasource": "TFA_Complexity",
181 "fieldConfig": {
182 "defaults": {
183 "custom": {}
184 },
185 "overrides": []
186 },
187 "fontSize": "100%",
188 "gridPos": {
189 "h": 9,
190 "w": 24,
191 "x": 0,
192 "y": 11
193 },
194 "id": 4,
195 "links": [],
196 "pageSize": 100,
197 "scroll": true,
198 "showHeader": true,
199 "sort": {
200 "col": 0,
201 "desc": true
202 },
203 "styles": [
204 {
205 "alias": "Time",
206 "align": "auto",
207 "dateFormat": "YYYY-MM-DD HH:mm:ss",
208 "pattern": "Time",
209 "type": "date"
210 },
211 {
212 "alias": "",
213 "align": "auto",
214 "colorMode": null,
215 "colors": [
216 "rgba(245, 54, 54, 0.9)",
217 "rgba(237, 129, 40, 0.89)",
218 "rgba(50, 172, 45, 0.97)"
219 ],
220 "decimals": 2,
221 "pattern": "/.*/",
222 "thresholds": [],
223 "type": "number",
224 "unit": "short"
225 }
226 ],
227 "targets": [
228 {
229 "dsType": "influxdb",
230 "groupBy": [
231 {
232 "params": [
233 "$__interval"
234 ],
235 "type": "time"
236 },
237 {
238 "params": [
239 "null"
240 ],
241 "type": "fill"
242 }
243 ],
244 "orderByTime": "ASC",
245 "policy": "default",
246 "query": "SELECT Base_Tag, Function_ID, Location, Score, Threshold, Whitelisted FROM \"TFA_Complexity_Statistics\" where ((Whitelisted =~ /^$Whitelisted$/ OR Whitelisted =~ /^no$/) AND $timeFilter AND Target_Tag =~ /^$TargetTag1$/) GROUP BY Target_Tag",
247 "rawQuery": true,
248 "refId": "A",
249 "resultFormat": "table",
250 "select": [
251 [
252 {
253 "params": [
254 "value"
255 ],
256 "type": "field"
257 },
258 {
259 "params": [],
260 "type": "mean"
261 }
262 ]
263 ],
264 "tags": []
265 }
266 ],
267 "title": "TFA Complexity Statistics for Target Tag $TargetTag1",
268 "transform": "table",
269 "type": "table-old"
270 },
271 {
272 "columns": [],
273 "datasource": "TFA_Complexity",
274 "fieldConfig": {
275 "defaults": {
276 "custom": {}
277 },
278 "overrides": []
279 },
280 "fontSize": "100%",
281 "gridPos": {
282 "h": 9,
283 "w": 24,
284 "x": 0,
285 "y": 20
286 },
287 "id": 7,
288 "links": [],
289 "pageSize": 100,
290 "scroll": true,
291 "showHeader": true,
292 "sort": {
293 "col": 0,
294 "desc": true
295 },
296 "styles": [
297 {
298 "alias": "Time",
299 "align": "auto",
300 "dateFormat": "YYYY-MM-DD HH:mm:ss",
301 "pattern": "Time",
302 "type": "date"
303 },
304 {
305 "alias": "",
306 "align": "auto",
307 "colorMode": null,
308 "colors": [
309 "rgba(245, 54, 54, 0.9)",
310 "rgba(237, 129, 40, 0.89)",
311 "rgba(50, 172, 45, 0.97)"
312 ],
313 "decimals": 2,
314 "pattern": "/.*/",
315 "thresholds": [],
316 "type": "number",
317 "unit": "short"
318 }
319 ],
320 "targets": [
321 {
322 "dsType": "influxdb",
323 "groupBy": [
324 {
325 "params": [
326 "$__interval"
327 ],
328 "type": "time"
329 },
330 {
331 "params": [
332 "null"
333 ],
334 "type": "fill"
335 }
336 ],
337 "orderByTime": "ASC",
338 "policy": "default",
339 "query": "SELECT Base_Tag, Function_ID, Location, Score, Threshold, Whitelisted FROM \"TFA_Complexity_Statistics\" where ((Whitelisted =~ /^$Whitelisted$/ OR Whitelisted =~ /^no$/) AND Target_Tag =~ /^$TargetTag2$/) GROUP BY Target_Tag",
340 "rawQuery": true,
341 "refId": "A",
342 "resultFormat": "table",
343 "select": [
344 [
345 {
346 "params": [
347 "value"
348 ],
349 "type": "field"
350 },
351 {
352 "params": [],
353 "type": "mean"
354 }
355 ]
356 ],
357 "tags": []
358 }
359 ],
360 "title": "TFA Complexity Statistics for Target Tag $TargetTag2",
361 "transform": "table",
362 "type": "table-old"
363 }
364 ],
365 "schemaVersion": 26,
366 "style": "dark",
367 "tags": [
368 "TFA_QUALITY_METRICS"
369 ],
370 "templating": {
371 "list": [
372 {
373 "allValue": null,
374 "current": {
375 "tags": [],
376 "text": "no",
377 "value": "no"
378 },
379 "hide": 0,
380 "includeAll": false,
381 "label": "Show data including \"whitelisted\" functions?",
382 "multi": false,
383 "name": "Whitelisted",
384 "options": [
385 {
386 "selected": false,
387 "text": "yes",
388 "value": "yes"
389 },
390 {
391 "selected": true,
392 "text": "no",
393 "value": "no"
394 }
395 ],
396 "query": "yes,no",
397 "skipUrlSync": false,
398 "type": "custom"
399 },
400 {
401 "allValue": null,
402 "current": {
403 "selected": false,
404 "text": "v2.3",
405 "value": "v2.3"
406 },
407 "datasource": "TFA_Complexity",
408 "definition": "SELECT LAST(Target_Tag) FROM (SELECT Target_Tag, Function_ID FROM TFA_Complexity_Statistics)",
409 "hide": 2,
410 "includeAll": false,
411 "label": "Target Tag 1",
412 "multi": false,
413 "name": "TargetTag1",
414 "options": [],
415 "query": "SELECT LAST(Target_Tag) FROM (SELECT Target_Tag, Function_ID FROM TFA_Complexity_Statistics)",
416 "refresh": 1,
417 "regex": "",
418 "skipUrlSync": false,
419 "sort": 0,
420 "tagValuesQuery": "",
421 "tags": [],
422 "tagsQuery": "",
423 "type": "query",
424 "useTags": false
425 },
426 {
427 "allValue": null,
428 "current": {
429 "selected": false,
430 "text": "v2.0",
431 "value": "v2.0"
432 },
433 "datasource": "TFA_Complexity",
434 "definition": "SHOW TAG VALUES WITH KEY=\"Target_Tag\"",
435 "hide": 0,
436 "includeAll": false,
437 "label": "Target Tag",
438 "multi": false,
439 "name": "TargetTag2",
440 "options": [],
441 "query": "SHOW TAG VALUES WITH KEY=\"Target_Tag\"",
442 "refresh": 1,
443 "regex": "",
444 "skipUrlSync": false,
445 "sort": 0,
446 "tagValuesQuery": "",
447 "tags": [],
448 "tagsQuery": "",
449 "type": "query",
450 "useTags": false
451 }
452 ]
453 },
454 "time": {
455 "from": "now-2y",
456 "to": "now"
457 },
458 "timepicker": {
459 "refresh_intervals": [
460 "5s",
461 "10s",
462 "30s",
463 "1m",
464 "5m",
465 "15m",
466 "30m",
467 "1h",
468 "2h",
469 "1d"
470 ],
471 "time_options": [
472 "5m",
473 "15m",
474 "1h",
475 "6h",
476 "12h",
477 "24h",
478 "2d",
479 "7d",
480 "30d"
481 ]
482 },
483 "timezone": "",
484 "title": "TFA_Complexity",
485 "uid": "tfa-complexity",
486 "version": 6
487}