Skip to content

Commit

Permalink
Fix Peak RPS calculation, shared tooltip and fix VU display in the Pe…
Browse files Browse the repository at this point in the history
…rformance Overview (#165)

* Shared tooltip and Peak RPS calculation

* fixes

* fixes

* fixes

* Remove ID

* fix
  • Loading branch information
Sea-you committed Apr 30, 2024
1 parent 4737495 commit 1a03ade
Showing 1 changed file with 53 additions and 25 deletions.
78 changes: 53 additions & 25 deletions grafana/dashboards/k6-prometheus.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,8 @@
"description": "Visualize k6 OSS results stored in Prometheus",
"editable": true,
"fiscalYearStartMonth": 0,
"graphTooltip": 0,
"gnetId": 19665,
"graphTooltip": 2,
"links": [
{
"asDropdown": false,
Expand Down Expand Up @@ -46,6 +47,7 @@
"mode": "palette-classic"
},
"custom": {
"axisBorderShow": false,
"axisCenteredZero": false,
"axisColorMode": "text",
"axisLabel": "",
Expand Down Expand Up @@ -212,7 +214,7 @@
"showLegend": true
},
"tooltip": {
"mode": "single",
"mode": "multi",
"sort": "none"
}
},
Expand All @@ -223,7 +225,7 @@
"uid": "${DS_PROMETHEUS}"
},
"editorMode": "code",
"expr": "avg(k6_vus{testid=~\"$testid\"})",
"expr": "sum(k6_vus{testid=~\"$testid\"})",
"instant": false,
"legendFormat": "vus",
"range": true,
Expand Down Expand Up @@ -339,9 +341,11 @@
"fields": "",
"values": false
},
"textMode": "auto"
"showPercentChange": false,
"textMode": "auto",
"wideLayout": true
},
"pluginVersion": "10.1.2",
"pluginVersion": "10.4.0",
"targets": [
{
"datasource": {
Expand Down Expand Up @@ -401,9 +405,11 @@
"fields": "",
"values": false
},
"textMode": "auto"
"showPercentChange": false,
"textMode": "auto",
"wideLayout": true
},
"pluginVersion": "10.1.2",
"pluginVersion": "10.4.0",
"targets": [
{
"datasource": {
Expand Down Expand Up @@ -462,9 +468,11 @@
"fields": "",
"values": false
},
"textMode": "auto"
"showPercentChange": false,
"textMode": "auto",
"wideLayout": true
},
"pluginVersion": "10.1.2",
"pluginVersion": "10.4.0",
"targets": [
{
"datasource": {
Expand All @@ -474,12 +482,19 @@
"editorMode": "code",
"expr": "sum(irate(k6_http_reqs_total{testid=~\"$testid\"}[$__rate_interval]))",
"instant": false,
"interval": "",
"legendFormat": "__auto",
"range": true,
"refId": "A"
}
],
"title": "Peak RPS",
"transformations": [
{
"id": "reduce",
"options": {}
}
],
"type": "stat"
},
{
Expand Down Expand Up @@ -524,9 +539,11 @@
"fields": "",
"values": false
},
"textMode": "auto"
"showPercentChange": false,
"textMode": "auto",
"wideLayout": true
},
"pluginVersion": "10.1.2",
"pluginVersion": "10.4.0",
"targets": [
{
"datasource": {
Expand Down Expand Up @@ -555,6 +572,7 @@
"mode": "palette-classic"
},
"custom": {
"axisBorderShow": false,
"axisCenteredZero": false,
"axisColorMode": "text",
"axisLabel": "",
Expand Down Expand Up @@ -660,6 +678,7 @@
"mode": "palette-classic"
},
"custom": {
"axisBorderShow": false,
"axisCenteredZero": false,
"axisColorMode": "text",
"axisLabel": "",
Expand Down Expand Up @@ -792,6 +811,7 @@
"mode": "palette-classic"
},
"custom": {
"axisBorderShow": false,
"axisCenteredZero": false,
"axisColorMode": "text",
"axisLabel": "",
Expand Down Expand Up @@ -827,7 +847,8 @@
"mode": "absolute",
"steps": [
{
"color": "green"
"color": "green",
"value": null
}
]
},
Expand Down Expand Up @@ -965,6 +986,7 @@
"mode": "palette-classic"
},
"custom": {
"axisBorderShow": false,
"axisCenteredZero": false,
"axisColorMode": "text",
"axisLabel": "",
Expand Down Expand Up @@ -1001,7 +1023,8 @@
"mode": "absolute",
"steps": [
{
"color": "green"
"color": "green",
"value": null
}
]
},
Expand Down Expand Up @@ -1144,6 +1167,7 @@
"mode": "palette-classic"
},
"custom": {
"axisBorderShow": false,
"axisCenteredZero": false,
"axisColorMode": "text",
"axisLabel": "",
Expand Down Expand Up @@ -1180,7 +1204,8 @@
"mode": "absolute",
"steps": [
{
"color": "green"
"color": "green",
"value": null
}
]
},
Expand Down Expand Up @@ -1349,7 +1374,8 @@
"mode": "absolute",
"steps": [
{
"color": "green"
"color": "green",
"value": null
}
]
}
Expand Down Expand Up @@ -1462,7 +1488,7 @@
"frameIndex": 2,
"showHeader": true
},
"pluginVersion": "10.1.2",
"pluginVersion": "10.4.0",
"targets": [
{
"datasource": {
Expand Down Expand Up @@ -1636,7 +1662,8 @@
"mode": "absolute",
"steps": [
{
"color": "green"
"color": "green",
"value": null
}
]
}
Expand Down Expand Up @@ -1711,7 +1738,7 @@
}
]
},
"pluginVersion": "10.1.2",
"pluginVersion": "10.4.0",
"targets": [
{
"datasource": {
Expand Down Expand Up @@ -1802,6 +1829,7 @@
"mode": "palette-classic"
},
"custom": {
"axisBorderShow": false,
"axisCenteredZero": false,
"axisColorMode": "text",
"axisLabel": "",
Expand Down Expand Up @@ -1839,7 +1867,8 @@
"mode": "absolute",
"steps": [
{
"color": "green"
"color": "green",
"value": null
}
]
},
Expand Down Expand Up @@ -1904,13 +1933,12 @@
"content": "### Visualize other k6 results \n\nAt the top of the dashboard, click `Add` and select `Visualization` from the dropdown menu. Choose the visualization type and input the PromQL queries for the `k6_` metric(s).\n\nAlternatively, click on the `Explore` icon on the menu bar and input the queries for the `k6_` metric(s). From `Explore`, you can add new Panels to this dashboard. \n\nNote that all <a href=\"https://k6.io/docs/using-k6/metrics/\" target=\"_blank\">k6 metrics</a> are prefixed with the `k6_` namespace when sent to Prometheus.",
"mode": "markdown"
},
"pluginVersion": "10.1.2",
"pluginVersion": "10.4.0",
"type": "text"
}
],
"refresh": "",
"schemaVersion": 38,
"style": "dark",
"schemaVersion": 39,
"tags": [
"prometheus",
"k6"
Expand All @@ -1921,7 +1949,7 @@
"current": {
"selected": false,
"text": "prometheus",
"value": "P1809F7CD0C75ACF3"
"value": "${DS_PROMETHEUS}"
},
"description": "Choose a Prometheus Data Source",
"hide": 0,
Expand Down Expand Up @@ -2021,6 +2049,6 @@
"timezone": "",
"title": "k6 Prometheus",
"uid": "ccbb2351-2ae2-462f-ae0e-f2c893ad1028",
"version": 1,
"version": 2,
"weekStart": ""
}
}

0 comments on commit 1a03ade

Please sign in to comment.