Skip to content

Commit 2a58a67

Browse files
committed
fix(rtcstats): improve accuracy of dashboard graphs
1 parent 3d46b41 commit 2a58a67

File tree

1 file changed

+168
-25
lines changed

1 file changed

+168
-25
lines changed

log-analyser/grafana-provisioning/dashboards/rtcstats.json

Lines changed: 168 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131
"color": {
3232
"mode": "thresholds"
3333
},
34+
"decimals": 0,
3435
"mappings": [],
3536
"thresholds": {
3637
"mode": "absolute",
@@ -49,8 +50,8 @@
4950
"overrides": [
5051
{
5152
"matcher": {
52-
"id": "byName",
53-
"options": "{__name__=\"rtcstats_session_count\", instance=\"rtcstats-server:8095\", job=\"prometheus\"}"
53+
"id": "byFrameRefID",
54+
"options": "session count"
5455
},
5556
"properties": [
5657
{
@@ -73,8 +74,8 @@
7374
},
7475
{
7576
"matcher": {
76-
"id": "byName",
77-
"options": "{__name__=\"rtcstats_session_error_count\", instance=\"rtcstats-server:8095\", job=\"prometheus\"}"
77+
"id": "byFrameRefID",
78+
"options": "error count"
7879
},
7980
"properties": [
8081
{
@@ -108,7 +109,7 @@
108109
"colorMode": "value",
109110
"graphMode": "area",
110111
"justifyMode": "auto",
111-
"orientation": "auto",
112+
"orientation": "horizontal",
112113
"reduceOptions": {
113114
"calcs": [
114115
"lastNotNull"
@@ -126,9 +127,9 @@
126127
"uid": "d301145e-8c4e-4027-bf6e-43e81f095020"
127128
},
128129
"disableTextWrap": false,
129-
"editorMode": "builder",
130+
"editorMode": "code",
130131
"exemplar": false,
131-
"expr": "rtcstats_session_count",
132+
"expr": "increase(rtcstats_session_count[$__range])",
132133
"format": "time_series",
133134
"fullMetaSearch": false,
134135
"includeNullMetadata": true,
@@ -144,8 +145,8 @@
144145
"uid": "d301145e-8c4e-4027-bf6e-43e81f095020"
145146
},
146147
"disableTextWrap": false,
147-
"editorMode": "builder",
148-
"expr": "rtcstats_session_error_count",
148+
"editorMode": "code",
149+
"expr": "increase(rtcstats_session_error_count[$__range])",
149150
"format": "time_series",
150151
"fullMetaSearch": false,
151152
"hide": false,
@@ -219,8 +220,8 @@
219220
"overrides": [
220221
{
221222
"matcher": {
222-
"id": "byName",
223-
"options": "{__name__=\"rtcstats_websocket_connections\", instance=\"rtcstats-server:8095\", job=\"prometheus\"}"
223+
"id": "byFrameRefID",
224+
"options": "A"
224225
},
225226
"properties": [
226227
{
@@ -231,8 +232,8 @@
231232
},
232233
{
233234
"matcher": {
234-
"id": "byName",
235-
"options": "{__name__=\"rtcstats_websocket_connection_error\", instance=\"rtcstats-server:8095\", job=\"prometheus\"}"
235+
"id": "byFrameRefID",
236+
"options": "B"
236237
},
237238
"properties": [
238239
{
@@ -269,7 +270,7 @@
269270
"uid": "d301145e-8c4e-4027-bf6e-43e81f095020"
270271
},
271272
"disableTextWrap": false,
272-
"editorMode": "builder",
273+
"editorMode": "code",
273274
"expr": "rtcstats_websocket_connections",
274275
"fullMetaSearch": false,
275276
"hide": false,
@@ -286,8 +287,8 @@
286287
"uid": "d301145e-8c4e-4027-bf6e-43e81f095020"
287288
},
288289
"disableTextWrap": false,
289-
"editorMode": "builder",
290-
"expr": "rtcstats_websocket_connection_error",
290+
"editorMode": "code",
291+
"expr": "rate(rtcstats_websocket_connection_error[$__rate_interval])",
291292
"fullMetaSearch": false,
292293
"hide": false,
293294
"includeNullMetadata": true,
@@ -358,7 +359,80 @@
358359
]
359360
}
360361
},
361-
"overrides": []
362+
"overrides": [
363+
{
364+
"matcher": {
365+
"id": "byFrameRefID",
366+
"options": "rtcstats"
367+
},
368+
"properties": [
369+
{
370+
"id": "displayName",
371+
"value": "rtcstats client"
372+
}
373+
]
374+
},
375+
{
376+
"matcher": {
377+
"id": "byFrameRefID",
378+
"options": "jvb"
379+
},
380+
"properties": [
381+
{
382+
"id": "displayName",
383+
"value": "jvb"
384+
}
385+
]
386+
},
387+
{
388+
"matcher": {
389+
"id": "byFrameRefID",
390+
"options": "jicofo"
391+
},
392+
"properties": [
393+
{
394+
"id": "displayName",
395+
"value": "jiconfo"
396+
}
397+
]
398+
},
399+
{
400+
"matcher": {
401+
"id": "byFrameRefID",
402+
"options": "jibri"
403+
},
404+
"properties": [
405+
{
406+
"id": "displayName",
407+
"value": "jibri"
408+
}
409+
]
410+
},
411+
{
412+
"matcher": {
413+
"id": "byFrameRefID",
414+
"options": "jigasi"
415+
},
416+
"properties": [
417+
{
418+
"id": "displayName",
419+
"value": "jigasi"
420+
}
421+
]
422+
},
423+
{
424+
"matcher": {
425+
"id": "byFrameRefID",
426+
"options": "unknown"
427+
},
428+
"properties": [
429+
{
430+
"id": "displayName",
431+
"value": "unknow"
432+
}
433+
]
434+
}
435+
]
362436
},
363437
"gridPos": {
364438
"h": 8,
@@ -372,7 +446,7 @@
372446
"calcs": [],
373447
"displayMode": "list",
374448
"placement": "bottom",
375-
"showLegend": false
449+
"showLegend": true
376450
},
377451
"tooltip": {
378452
"mode": "single",
@@ -386,15 +460,84 @@
386460
"uid": "d301145e-8c4e-4027-bf6e-43e81f095020"
387461
},
388462
"disableTextWrap": false,
389-
"editorMode": "builder",
390-
"expr": "rtcstats_dump_size_bytes_count",
463+
"editorMode": "code",
464+
"expr": "increase(rtcstats_dump_size_bytes_count[$__rate_interval])",
391465
"fullMetaSearch": false,
392466
"includeNullMetadata": true,
393467
"instant": false,
394468
"legendFormat": "__auto",
395469
"range": true,
396-
"refId": "A",
470+
"refId": "rtcstats",
397471
"useBackend": false
472+
},
473+
{
474+
"datasource": {
475+
"type": "prometheus",
476+
"uid": "d301145e-8c4e-4027-bf6e-43e81f095020"
477+
},
478+
"disableTextWrap": false,
479+
"editorMode": "code",
480+
"expr": "increase(jvb_dump_size_bytes_count[$__rate_interval])",
481+
"fullMetaSearch": false,
482+
"hide": false,
483+
"includeNullMetadata": true,
484+
"instant": false,
485+
"legendFormat": "__auto",
486+
"range": true,
487+
"refId": "jvb",
488+
"useBackend": false
489+
},
490+
{
491+
"datasource": {
492+
"type": "prometheus",
493+
"uid": "d301145e-8c4e-4027-bf6e-43e81f095020"
494+
},
495+
"editorMode": "code",
496+
"expr": "increase(jicofo_dump_size_bytes_count[$__rate_interval])",
497+
"hide": false,
498+
"instant": false,
499+
"legendFormat": "__auto",
500+
"range": true,
501+
"refId": "jicofo"
502+
},
503+
{
504+
"datasource": {
505+
"type": "prometheus",
506+
"uid": "d301145e-8c4e-4027-bf6e-43e81f095020"
507+
},
508+
"editorMode": "code",
509+
"expr": "increase(jibri_dump_size_bytes_count[$__rate_interval])",
510+
"hide": false,
511+
"instant": false,
512+
"legendFormat": "__auto",
513+
"range": true,
514+
"refId": "jibri"
515+
},
516+
{
517+
"datasource": {
518+
"type": "prometheus",
519+
"uid": "d301145e-8c4e-4027-bf6e-43e81f095020"
520+
},
521+
"editorMode": "code",
522+
"expr": "increase(jigasi_dump_size_bytes_count[$__rate_interval])",
523+
"hide": false,
524+
"instant": false,
525+
"legendFormat": "__auto",
526+
"range": true,
527+
"refId": "jigasi"
528+
},
529+
{
530+
"datasource": {
531+
"type": "prometheus",
532+
"uid": "d301145e-8c4e-4027-bf6e-43e81f095020"
533+
},
534+
"editorMode": "code",
535+
"expr": "increase(unknown_dump_size_bytes_count[$__rate_interval])",
536+
"hide": false,
537+
"instant": false,
538+
"legendFormat": "__auto",
539+
"range": true,
540+
"refId": "unknown"
398541
}
399542
],
400543
"title": "Dump Size Bytes Count",
@@ -486,7 +629,7 @@
486629
"uid": "d301145e-8c4e-4027-bf6e-43e81f095020"
487630
},
488631
"disableTextWrap": false,
489-
"editorMode": "builder",
632+
"editorMode": "code",
490633
"exemplar": false,
491634
"expr": "rtcstats_disk_queue_size",
492635
"format": "time_series",
@@ -504,20 +647,20 @@
504647
"type": "timeseries"
505648
}
506649
],
507-
"refresh": "5s",
650+
"refresh": "30s",
508651
"schemaVersion": 38,
509652
"tags": [],
510653
"templating": {
511654
"list": []
512655
},
513656
"time": {
514-
"from": "now-30m",
657+
"from": "now-6h",
515658
"to": "now"
516659
},
517660
"timepicker": {},
518661
"timezone": "",
519662
"title": "rtcstats",
520663
"uid": "e4e8c548-c977-4f95-bc91-995d0a757f8e",
521-
"version": 1,
664+
"version": 2,
522665
"weekStart": ""
523666
}

0 commit comments

Comments
 (0)