Antonio Mika
·
04 Aug 22
caddy-metrics.json
1{
2 "annotations": {
3 "list": [
4 {
5 "builtIn": 1,
6 "datasource": {
7 "type": "datasource",
8 "uid": "grafana"
9 },
10 "enable": true,
11 "hide": true,
12 "iconColor": "rgba(0, 211, 255, 1)",
13 "limit": 100,
14 "name": "Annotations & Alerts",
15 "showIn": 0,
16 "target": {
17 "limit": 100,
18 "matchAny": false,
19 "tags": [],
20 "type": "dashboard"
21 },
22 "type": "dashboard"
23 }
24 ]
25 },
26 "editable": true,
27 "fiscalYearStartMonth": 0,
28 "gnetId": 13460,
29 "graphTooltip": 0,
30 "links": [],
31 "liveNow": false,
32 "panels": [
33 {
34 "datasource": {
35 "type": "prometheus",
36 "uid": "PBFA97CFB590B2093"
37 },
38 "fieldConfig": {
39 "defaults": {
40 "color": {
41 "mode": "palette-classic"
42 },
43 "custom": {
44 "axisLabel": "",
45 "axisPlacement": "auto",
46 "barAlignment": 0,
47 "drawStyle": "line",
48 "fillOpacity": 10,
49 "gradientMode": "none",
50 "hideFrom": {
51 "legend": false,
52 "tooltip": false,
53 "viz": false
54 },
55 "lineInterpolation": "linear",
56 "lineWidth": 2,
57 "pointSize": 5,
58 "scaleDistribution": {
59 "log": 10,
60 "type": "log"
61 },
62 "showPoints": "never",
63 "spanNulls": false,
64 "stacking": {
65 "group": "A",
66 "mode": "none"
67 },
68 "thresholdsStyle": {
69 "mode": "off"
70 }
71 },
72 "mappings": [],
73 "thresholds": {
74 "mode": "absolute",
75 "steps": [
76 {
77 "color": "green",
78 "value": null
79 },
80 {
81 "color": "red",
82 "value": 80
83 }
84 ]
85 },
86 "unit": "short"
87 },
88 "overrides": []
89 },
90 "gridPos": {
91 "h": 9,
92 "w": 12,
93 "x": 0,
94 "y": 0
95 },
96 "id": 2,
97 "options": {
98 "legend": {
99 "calcs": [
100 "min",
101 "max",
102 "mean"
103 ],
104 "displayMode": "table",
105 "placement": "bottom",
106 "sortBy": "Mean",
107 "sortDesc": true
108 },
109 "tooltip": {
110 "mode": "multi",
111 "sort": "none"
112 }
113 },
114 "pluginVersion": "9.0.5",
115 "targets": [
116 {
117 "datasource": {
118 "type": "prometheus",
119 "uid": "PBFA97CFB590B2093"
120 },
121 "editorMode": "code",
122 "expr": "sum(rate(caddy_http_requests_total{handler=~\"$handler\", instance=~\"$instance\"}[1m])) by (instance, handler)",
123 "interval": "",
124 "legendFormat": "{{instance}} - {{handler}}",
125 "range": true,
126 "refId": "A"
127 }
128 ],
129 "title": "Requests",
130 "type": "timeseries"
131 },
132 {
133 "datasource": {
134 "type": "prometheus",
135 "uid": "PBFA97CFB590B2093"
136 },
137 "description": "",
138 "fieldConfig": {
139 "defaults": {
140 "color": {
141 "mode": "palette-classic"
142 },
143 "custom": {
144 "axisLabel": "",
145 "axisPlacement": "auto",
146 "barAlignment": 0,
147 "drawStyle": "line",
148 "fillOpacity": 10,
149 "gradientMode": "none",
150 "hideFrom": {
151 "legend": false,
152 "tooltip": false,
153 "viz": false
154 },
155 "lineInterpolation": "linear",
156 "lineWidth": 2,
157 "pointSize": 5,
158 "scaleDistribution": {
159 "type": "linear"
160 },
161 "showPoints": "never",
162 "spanNulls": false,
163 "stacking": {
164 "group": "A",
165 "mode": "normal"
166 },
167 "thresholdsStyle": {
168 "mode": "off"
169 }
170 },
171 "mappings": [],
172 "thresholds": {
173 "mode": "absolute",
174 "steps": [
175 {
176 "color": "green",
177 "value": null
178 },
179 {
180 "color": "red",
181 "value": 80
182 }
183 ]
184 },
185 "unit": "short"
186 },
187 "overrides": []
188 },
189 "gridPos": {
190 "h": 9,
191 "w": 12,
192 "x": 12,
193 "y": 0
194 },
195 "id": 7,
196 "options": {
197 "legend": {
198 "calcs": [
199 "min",
200 "max",
201 "mean"
202 ],
203 "displayMode": "table",
204 "placement": "bottom",
205 "sortBy": "Mean",
206 "sortDesc": true
207 },
208 "tooltip": {
209 "mode": "multi",
210 "sort": "none"
211 }
212 },
213 "pluginVersion": "9.0.5",
214 "targets": [
215 {
216 "datasource": {
217 "type": "prometheus",
218 "uid": "PBFA97CFB590B2093"
219 },
220 "editorMode": "code",
221 "expr": "sum(irate(caddy_http_request_duration_seconds_count{instance=~\"$instance\", handler=~\"$handler\"}[1m])) by (code, instance, handler)",
222 "interval": "",
223 "legendFormat": "{{instance}} - {{handler}} - {{code}}",
224 "range": true,
225 "refId": "A"
226 }
227 ],
228 "title": "Requests by Response Code",
229 "type": "timeseries"
230 },
231 {
232 "datasource": {
233 "type": "prometheus",
234 "uid": "PBFA97CFB590B2093"
235 },
236 "fieldConfig": {
237 "defaults": {
238 "color": {
239 "mode": "palette-classic"
240 },
241 "custom": {
242 "axisLabel": "",
243 "axisPlacement": "auto",
244 "barAlignment": 0,
245 "drawStyle": "line",
246 "fillOpacity": 10,
247 "gradientMode": "none",
248 "hideFrom": {
249 "legend": false,
250 "tooltip": false,
251 "viz": false
252 },
253 "lineInterpolation": "linear",
254 "lineWidth": 2,
255 "pointSize": 5,
256 "scaleDistribution": {
257 "type": "linear"
258 },
259 "showPoints": "never",
260 "spanNulls": false,
261 "stacking": {
262 "group": "A",
263 "mode": "none"
264 },
265 "thresholdsStyle": {
266 "mode": "off"
267 }
268 },
269 "mappings": [],
270 "thresholds": {
271 "mode": "absolute",
272 "steps": [
273 {
274 "color": "green",
275 "value": null
276 },
277 {
278 "color": "red",
279 "value": 80
280 }
281 ]
282 },
283 "unit": "short"
284 },
285 "overrides": []
286 },
287 "gridPos": {
288 "h": 9,
289 "w": 12,
290 "x": 0,
291 "y": 9
292 },
293 "id": 8,
294 "options": {
295 "legend": {
296 "calcs": [
297 "min",
298 "max",
299 "mean"
300 ],
301 "displayMode": "table",
302 "placement": "bottom",
303 "sortBy": "Mean",
304 "sortDesc": true
305 },
306 "tooltip": {
307 "mode": "multi",
308 "sort": "none"
309 }
310 },
311 "pluginVersion": "9.0.5",
312 "targets": [
313 {
314 "datasource": {
315 "type": "prometheus",
316 "uid": "PBFA97CFB590B2093"
317 },
318 "editorMode": "code",
319 "expr": "avg_over_time(caddy_http_requests_in_flight{instance=~\"$instance\", handler=~\"$handler\"}[1m])",
320 "hide": false,
321 "interval": "",
322 "legendFormat": "{{instance}} - {{handler}}",
323 "range": true,
324 "refId": "E"
325 }
326 ],
327 "title": "Requests In Flight",
328 "type": "timeseries"
329 },
330 {
331 "datasource": {
332 "type": "prometheus",
333 "uid": "PBFA97CFB590B2093"
334 },
335 "description": "",
336 "fieldConfig": {
337 "defaults": {
338 "color": {
339 "mode": "palette-classic"
340 },
341 "custom": {
342 "axisLabel": "",
343 "axisPlacement": "auto",
344 "barAlignment": 0,
345 "drawStyle": "bars",
346 "fillOpacity": 100,
347 "gradientMode": "none",
348 "hideFrom": {
349 "legend": false,
350 "tooltip": false,
351 "viz": false
352 },
353 "lineInterpolation": "linear",
354 "lineWidth": 2,
355 "pointSize": 5,
356 "scaleDistribution": {
357 "type": "linear"
358 },
359 "showPoints": "never",
360 "spanNulls": false,
361 "stacking": {
362 "group": "A",
363 "mode": "normal"
364 },
365 "thresholdsStyle": {
366 "mode": "off"
367 }
368 },
369 "mappings": [],
370 "min": 0,
371 "thresholds": {
372 "mode": "absolute",
373 "steps": [
374 {
375 "color": "green",
376 "value": null
377 },
378 {
379 "color": "red",
380 "value": 80
381 }
382 ]
383 },
384 "unit": "none"
385 },
386 "overrides": []
387 },
388 "gridPos": {
389 "h": 9,
390 "w": 12,
391 "x": 12,
392 "y": 9
393 },
394 "id": 5,
395 "options": {
396 "legend": {
397 "calcs": [
398 "min",
399 "max",
400 "mean"
401 ],
402 "displayMode": "table",
403 "placement": "bottom",
404 "sortBy": "Mean",
405 "sortDesc": true
406 },
407 "tooltip": {
408 "mode": "multi",
409 "sort": "none"
410 }
411 },
412 "pluginVersion": "9.0.5",
413 "targets": [
414 {
415 "datasource": {
416 "type": "prometheus",
417 "uid": "PBFA97CFB590B2093"
418 },
419 "editorMode": "code",
420 "expr": "sum(irate(caddy_http_request_duration_seconds_count{instance=~\"$instance\", handler=~\"$handler\"}[1m])) by (code, instance, handler)",
421 "interval": "",
422 "legendFormat": "{{instance}} - {{handler}} - {{code}}",
423 "range": true,
424 "refId": "A"
425 }
426 ],
427 "title": "Requests by Response Code (%)",
428 "type": "timeseries"
429 },
430 {
431 "datasource": {
432 "type": "prometheus",
433 "uid": "PBFA97CFB590B2093"
434 },
435 "fieldConfig": {
436 "defaults": {
437 "color": {
438 "mode": "palette-classic"
439 },
440 "custom": {
441 "axisLabel": "",
442 "axisPlacement": "auto",
443 "barAlignment": 0,
444 "drawStyle": "line",
445 "fillOpacity": 10,
446 "gradientMode": "none",
447 "hideFrom": {
448 "legend": false,
449 "tooltip": false,
450 "viz": false
451 },
452 "lineInterpolation": "linear",
453 "lineWidth": 2,
454 "pointSize": 5,
455 "scaleDistribution": {
456 "log": 2,
457 "type": "log"
458 },
459 "showPoints": "never",
460 "spanNulls": false,
461 "stacking": {
462 "group": "A",
463 "mode": "none"
464 },
465 "thresholdsStyle": {
466 "mode": "off"
467 }
468 },
469 "mappings": [],
470 "thresholds": {
471 "mode": "absolute",
472 "steps": [
473 {
474 "color": "green",
475 "value": null
476 },
477 {
478 "color": "red",
479 "value": 80
480 }
481 ]
482 },
483 "unit": "s"
484 },
485 "overrides": []
486 },
487 "gridPos": {
488 "h": 9,
489 "w": 12,
490 "x": 0,
491 "y": 18
492 },
493 "id": 4,
494 "options": {
495 "legend": {
496 "calcs": [
497 "min",
498 "max",
499 "mean"
500 ],
501 "displayMode": "table",
502 "placement": "bottom",
503 "sortBy": "Mean",
504 "sortDesc": true
505 },
506 "tooltip": {
507 "mode": "multi",
508 "sort": "none"
509 }
510 },
511 "pluginVersion": "9.0.5",
512 "targets": [
513 {
514 "datasource": {
515 "type": "prometheus",
516 "uid": "PBFA97CFB590B2093"
517 },
518 "editorMode": "code",
519 "expr": "histogram_quantile(0.99, sum(rate(caddy_http_request_duration_seconds_bucket{instance=~\"$instance\", handler=~\"$handler\"}[1m])) by (le, instance, handler))",
520 "interval": "",
521 "legendFormat": "p99 - {{instance}} - {{handler}}",
522 "range": true,
523 "refId": "A"
524 },
525 {
526 "datasource": {
527 "type": "prometheus",
528 "uid": "PBFA97CFB590B2093"
529 },
530 "editorMode": "code",
531 "expr": "histogram_quantile(0.95, sum(rate(caddy_http_request_duration_seconds_bucket{instance=~\"$instance\", handler=~\"$handler\"}[1m])) by (le, instance, handler))",
532 "interval": "",
533 "legendFormat": "p95 - {{instance}} - {{handler}}",
534 "range": true,
535 "refId": "B"
536 },
537 {
538 "datasource": {
539 "type": "prometheus",
540 "uid": "PBFA97CFB590B2093"
541 },
542 "editorMode": "code",
543 "expr": "histogram_quantile(0.90, sum(rate(caddy_http_request_duration_seconds_bucket{instance=~\"$instance\", handler=~\"$handler\"}[1m])) by (le, instance, handler))",
544 "interval": "",
545 "legendFormat": "p90 - {{instance}} - {{handler}}",
546 "range": true,
547 "refId": "C"
548 },
549 {
550 "datasource": {
551 "type": "prometheus",
552 "uid": "PBFA97CFB590B2093"
553 },
554 "editorMode": "code",
555 "expr": "histogram_quantile(0.75, sum(rate(caddy_http_request_duration_seconds_bucket{instance=~\"$instance\", handler=~\"$handler\"}[1m])) by (le, instance, handler))",
556 "interval": "",
557 "legendFormat": "p75 - {{instance}} - {{handler}}",
558 "range": true,
559 "refId": "D"
560 },
561 {
562 "datasource": {
563 "type": "prometheus",
564 "uid": "PBFA97CFB590B2093"
565 },
566 "editorMode": "code",
567 "expr": "histogram_quantile(0.5, sum(rate(caddy_http_request_duration_seconds_bucket{instance=~\"$instance\", handler=~\"$handler\"}[1m])) by (le, instance, handler))",
568 "interval": "",
569 "legendFormat": "p50 - {{instance}} - {{handler}}",
570 "range": true,
571 "refId": "E"
572 }
573 ],
574 "title": "Request Duration (percentile)",
575 "type": "timeseries"
576 },
577 {
578 "cards": {},
579 "color": {
580 "cardColor": "#b4ff00",
581 "colorScale": "linear",
582 "colorScheme": "interpolateInferno",
583 "exponent": 0.5,
584 "mode": "spectrum"
585 },
586 "dataFormat": "tsbuckets",
587 "datasource": {
588 "type": "prometheus",
589 "uid": "PBFA97CFB590B2093"
590 },
591 "gridPos": {
592 "h": 9,
593 "w": 12,
594 "x": 12,
595 "y": 18
596 },
597 "heatmap": {},
598 "hideZeroBuckets": true,
599 "highlightCards": true,
600 "id": 6,
601 "interval": "",
602 "legend": {
603 "show": true
604 },
605 "maxDataPoints": 25,
606 "pluginVersion": "7.1.0",
607 "reverseYBuckets": false,
608 "targets": [
609 {
610 "datasource": {
611 "type": "prometheus",
612 "uid": "PBFA97CFB590B2093"
613 },
614 "editorMode": "code",
615 "expr": "sum(increase(caddy_http_request_duration_seconds_bucket{instance=~\"$instance\", handler=~\"$handler\"}[5m])) by (le, instance, handler)",
616 "format": "heatmap",
617 "interval": "",
618 "legendFormat": "{{le}} - {{instance}} - {{handler}}",
619 "range": true,
620 "refId": "A"
621 }
622 ],
623 "title": "Request Duration (heatmap)",
624 "tooltip": {
625 "show": true,
626 "showHistogram": false
627 },
628 "type": "heatmap",
629 "xAxis": {
630 "show": true
631 },
632 "yAxis": {
633 "format": "s",
634 "logBase": 1,
635 "show": true
636 },
637 "yBucketBound": "auto"
638 }
639 ],
640 "refresh": false,
641 "schemaVersion": 36,
642 "style": "dark",
643 "tags": [
644 "http",
645 "caddy",
646 "prometheus"
647 ],
648 "templating": {
649 "list": [
650 {
651 "current": {
652 "selected": true,
653 "text": [
654 "prose.sh:443"
655 ],
656 "value": [
657 "prose.sh:443"
658 ]
659 },
660 "datasource": {
661 "type": "prometheus",
662 "uid": "PBFA97CFB590B2093"
663 },
664 "definition": "label_values(caddy_http_requests_total, instance)",
665 "hide": 0,
666 "includeAll": true,
667 "label": "Instance",
668 "multi": true,
669 "name": "instance",
670 "options": [],
671 "query": {
672 "query": "label_values(caddy_http_requests_total, instance)",
673 "refId": "StandardVariableQuery"
674 },
675 "refresh": 2,
676 "regex": "",
677 "skipUrlSync": false,
678 "sort": 0,
679 "type": "query"
680 },
681 {
682 "current": {
683 "selected": true,
684 "text": [
685 "reverse_proxy"
686 ],
687 "value": [
688 "reverse_proxy"
689 ]
690 },
691 "datasource": {
692 "type": "prometheus",
693 "uid": "PBFA97CFB590B2093"
694 },
695 "definition": "label_values(caddy_http_requests_total{instance=~\"$instance\"}, handler)",
696 "hide": 0,
697 "includeAll": true,
698 "label": "handler",
699 "multi": true,
700 "name": "handler",
701 "options": [],
702 "query": {
703 "query": "label_values(caddy_http_requests_total{instance=~\"$instance\"}, handler)",
704 "refId": "StandardVariableQuery"
705 },
706 "refresh": 2,
707 "regex": "",
708 "skipUrlSync": false,
709 "sort": 1,
710 "tagValuesQuery": "",
711 "tagsQuery": "",
712 "type": "query",
713 "useTags": false
714 }
715 ]
716 },
717 "time": {
718 "from": "now-15m",
719 "to": "now"
720 },
721 "timepicker": {
722 "refresh_intervals": [
723 "10s",
724 "30s",
725 "1m",
726 "5m",
727 "15m",
728 "30m",
729 "1h",
730 "2h",
731 "1d"
732 ]
733 },
734 "timezone": "",
735 "title": "Caddy",
736 "uid": "TZBbz9TMk",
737 "version": 5,
738 "weekStart": ""
739}