Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
87 changes: 55 additions & 32 deletions src/grafana_dashboards/metrics_prometheus.json
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"fieldConfig": {
"defaults": {
Expand Down Expand Up @@ -116,7 +116,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"editorMode": "code",
"exemplar": false,
Expand All @@ -135,7 +135,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"description": "The amount of time a runner is not used.",
"fieldConfig": {
Expand Down Expand Up @@ -214,7 +214,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"editorMode": "code",
"expr": "histogram_quantile(1, sum by(flavor, le) (rate(runner_idle_duration_seconds_bucket[10m])))",
Expand All @@ -229,7 +229,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"description": "Duration of reconciliation (seconds)",
"fieldConfig": {
Expand Down Expand Up @@ -308,7 +308,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"editorMode": "code",
"expr": "histogram_quantile(1, sum(rate(reconcile_duration_seconds_bucket[10m])) by (flavor, le))",
Expand All @@ -323,7 +323,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"description": "Time in seconds to initialize the VM and register the runner on GitHub.",
"fieldConfig": {
Expand Down Expand Up @@ -402,7 +402,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"editorMode": "code",
"expr": "histogram_quantile(1, sum by (flavor, le) (rate(runner_spawn_duration_seconds_bucket[10m]))) ",
Expand All @@ -417,7 +417,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"description": "",
"fieldConfig": {
Expand Down Expand Up @@ -496,7 +496,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"editorMode": "code",
"expr": "histogram_quantile(\n $quantile,\n sum by (flavor, le) (\n rate(delete_vm_duration_seconds_bucket[10m])\n )\n)",
Expand All @@ -511,7 +511,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"description": "Number of seconds taken to delete runners from GitHub for each reconcile",
"fieldConfig": {
Expand Down Expand Up @@ -590,7 +590,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"editorMode": "code",
"expr": "histogram_quantile($quantile, sum by (flavor, le) (rate(delete_runner_duration_seconds_bucket[10m])))",
Expand All @@ -605,7 +605,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"description": "OpenStack Server List response time",
"fieldConfig": {
Expand Down Expand Up @@ -684,7 +684,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"editorMode": "code",
"expr": "histogram_quantile(\n $quantile,\n sum by (le) (\n rate(openstack_http_response_time_bucket{endpoint=~\".*servers/detail\"}[10m])\n )\n)",
Expand Down Expand Up @@ -712,7 +712,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"fieldConfig": {
"defaults": {
Expand Down Expand Up @@ -763,7 +763,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"editorMode": "code",
"expr": "sum by (flavor) (expected_runners_count)",
Expand All @@ -778,7 +778,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"description": "Expected runners count - (idle runners count + busy runners count)",
"fieldConfig": {
Expand Down Expand Up @@ -830,7 +830,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"editorMode": "code",
"expr": "abs(expected_runners_count - (idle_runners_count + busy_runners_count))",
Expand All @@ -845,7 +845,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"fieldConfig": {
"defaults": {
Expand Down Expand Up @@ -922,7 +922,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"editorMode": "code",
"expr": "sum by(flavor) (idle_runners_count)",
Expand All @@ -937,7 +937,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"fieldConfig": {
"defaults": {
Expand Down Expand Up @@ -1014,7 +1014,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"editorMode": "code",
"expr": "sum by (flavor) (busy_runners_count)",
Expand Down Expand Up @@ -1042,7 +1042,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"description": "The number of GitHub runners not found on GitHub but exists on cloud.",
"fieldConfig": {
Expand Down Expand Up @@ -1120,7 +1120,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"editorMode": "code",
"expr": "sum by(juju_application) (increase(missing_runners_total[$__rate_interval]))",
Expand All @@ -1135,7 +1135,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"description": "The number of VMs deleted during reconciliation.",
"fieldConfig": {
Expand Down Expand Up @@ -1213,7 +1213,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"editorMode": "code",
"expr": "sum by(juju_application) (increase(deleted_vms_total[$__rate_interval]))",
Expand All @@ -1228,7 +1228,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"description": "The number of GitHub runners without an underlying VM.",
"fieldConfig": {
Expand Down Expand Up @@ -1306,7 +1306,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"editorMode": "code",
"expr": "sum by(juju_application) (increase(dangling_runners_total[$__rate_interval]))",
Expand All @@ -1321,7 +1321,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"description": "The number of removed runners from GitHub during reconciliation.",
"fieldConfig": {
Expand Down Expand Up @@ -1399,7 +1399,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"editorMode": "builder",
"expr": "sum by(juju_application) (increase(deleted_runners_total[$__rate_interval]))",
Expand All @@ -1414,7 +1414,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"description": "The number of GitHub runners that are older than maximum creation time but has not yet come online nor taken a job.",
"fieldConfig": {
Expand Down Expand Up @@ -1492,7 +1492,7 @@
{
"datasource": {
"type": "prometheus",
"uid": "PE6731821AF182E02"
"uid": "${prometheusds}"
},
"editorMode": "code",
"expr": "sum by(juju_application) (increase(timed_out_runners_total[$__rate_interval]))",
Expand All @@ -1511,6 +1511,29 @@
"tags": [],
"templating": {
"list": [
{
"current": {
"selected": true,
"text": [
"All"
],
"value": [
"$__all"
]
},
"hide": 0,
"includeAll": true,
"label": "Prometheus datasource",
"multi": true,
"name": "prometheusds",
"options": [],
"query": "prometheus",
"queryValue": "",
"refresh": 1,
"regex": "",
"skipUrlSync": false,
"type": "datasource"
},
Comment on lines +1514 to +1536

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@copilot please remove this template, the prometheus datasource has been defined by the pr

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can remove the template variable, but what should the datasource UID references be changed to instead of ${prometheusds}? Should they be:

  • null (to use default datasource)
  • "$__all"
  • A specific UID that the PR provides
  • Something else?

The original feedback requested replacing the hardcoded PE6731821AF182E02 with a template variable, so I want to make sure I use the correct approach.

{
"current": {
"selected": false,
Expand Down