Commit f4cc0734 authored by Lluis Gifre Renom's avatar Lluis Gifre Renom
Browse files

WebUI - Grafana:

- updated dashboard to include names instead of UUIDs
- corrected database/table names
- corrected default attributes
parent e67f3597
Loading
Loading
Loading
Loading
+29 −27
Original line number Diff line number Diff line
@@ -26,14 +26,14 @@
    "editable": true,
    "fiscalYearStartMonth": 0,
    "graphTooltip": 0,
    "iteration": 1664814762635,
    "iteration": 1675103296430,
    "links": [],
    "liveNow": false,
    "panels": [
      {
        "datasource": {
          "type": "postgres",
          "uid": "monitoringdb"
          "uid": "questdb"
        },
        "fieldConfig": {
          "defaults": {
@@ -162,14 +162,14 @@
          {
            "datasource": {
              "type": "postgres",
              "uid": "monitoringdb"
              "uid": "questdb"
            },
            "format": "time_series",
            "group": [],
            "hide": false,
            "metricColumn": "kpi_value",
            "rawQuery": true,
            "rawSql": "SELECT\r\n  $__time(timestamp), kpi_value AS metric, device_id, endpoint_id, kpi_sample_type\r\nFROM\r\n  monitoring\r\nWHERE\r\n  $__timeFilter(timestamp) AND device_id IN ($device_id) AND endpoint_id IN ($endpoint_id) AND kpi_sample_type IN ($kpi_sample_type)\r\nGROUP BY\r\n  device_id, endpoint_id, kpi_sample_type\r\nORDER BY\r\n  timestamp\r\n",
            "rawSql": "SELECT\r\n  $__time(timestamp), kpi_value AS metric, device_name, endpoint_name, kpi_sample_type\r\nFROM\r\n  tfs_monitoring\r\nWHERE\r\n  $__timeFilter(timestamp) AND device_name IN (${device_name}) AND endpoint_name IN (${endpoint_name}) AND kpi_sample_type IN (${kpi_sample_type})\r\nGROUP BY\r\n  device_name, endpoint_name, kpi_sample_type\r\nORDER BY\r\n  timestamp",
            "refId": "A",
            "select": [
              [
@@ -201,8 +201,8 @@
          {
            "id": "renameByRegex",
            "options": {
              "regex": "metric {device_id=\\\"([^\\\"]+)\\\", endpoint_id=\\\"([^\\\"]+)\\\", kpi_sample_type=\\\"([^\\\"]+)\\\"}",
              "renamePattern": "$3 ($1 $2)"
              "regex": "metric {device_name=\\\"([^\\\"]+)\\\", endpoint_name=\\\"([^\\\"]+)\\\", kpi_sample_type=\\\"([^\\\"]+)\\\"}",
              "renamePattern": "$3 ($1 : $2)"
            }
          }
        ],
@@ -227,16 +227,16 @@
          },
          "datasource": {
            "type": "postgres",
            "uid": "monitoringdb"
            "uid": "questdb"
          },
          "definition": "SELECT DISTINCT device_id FROM monitoring;",
          "definition": "SELECT DISTINCT device_name FROM tfs_monitoring;",
          "hide": 0,
          "includeAll": true,
          "label": "Device",
          "multi": true,
          "name": "device_id",
          "name": "device_name",
          "options": [],
          "query": "SELECT DISTINCT device_id FROM monitoring;",
          "query": "SELECT DISTINCT device_name FROM tfs_monitoring;",
          "refresh": 2,
          "regex": "",
          "skipUrlSync": false,
@@ -245,22 +245,26 @@
        },
        {
          "current": {
            "selected": false,
            "text": "All",
            "value": "$__all"
            "selected": true,
            "text": [
              "All"
            ],
            "value": [
              "$__all"
            ]
          },
          "datasource": {
            "type": "postgres",
            "uid": "monitoringdb"
            "uid": "questdb"
          },
          "definition": "SELECT DISTINCT endpoint_id FROM monitoring WHERE device_id IN (${device_id})",
          "definition": "SELECT DISTINCT endpoint_name FROM tfs_monitoring WHERE device_name IN (${device_name})",
          "hide": 0,
          "includeAll": true,
          "label": "EndPoint",
          "multi": true,
          "name": "endpoint_id",
          "name": "endpoint_name",
          "options": [],
          "query": "SELECT DISTINCT endpoint_id FROM monitoring WHERE device_id IN (${device_id})",
          "query": "SELECT DISTINCT endpoint_name FROM tfs_monitoring WHERE device_name IN (${device_name})",
          "refresh": 2,
          "regex": "",
          "skipUrlSync": false,
@@ -271,26 +275,24 @@
          "current": {
            "selected": true,
            "text": [
              "PACKETS_RECEIVED",
              "PACKETS_TRANSMITTED"
              "All"
            ],
            "value": [
              "PACKETS_RECEIVED",
              "PACKETS_TRANSMITTED"
              "$__all"
            ]
          },
          "datasource": {
            "type": "postgres",
            "uid": "monitoringdb"
            "uid": "questdb"
          },
          "definition": "SELECT DISTINCT kpi_sample_type FROM monitoring;",
          "definition": "SELECT DISTINCT kpi_sample_type FROM tfs_monitoring;",
          "hide": 0,
          "includeAll": true,
          "label": "Kpi Sample Type",
          "multi": true,
          "name": "kpi_sample_type",
          "options": [],
          "query": "SELECT DISTINCT kpi_sample_type FROM monitoring;",
          "query": "SELECT DISTINCT kpi_sample_type FROM tfs_monitoring;",
          "refresh": 2,
          "regex": "",
          "skipUrlSync": false,
@@ -300,14 +302,14 @@
      ]
    },
    "time": {
      "from": "now-15m",
      "from": "now-5m",
      "to": "now"
    },
    "timepicker": {},
    "timezone": "",
    "timezone": "utc",
    "title": "L3 Monitoring",
    "uid": "tf-l3-monit",
    "version": 1,
    "version": 6,
    "weekStart": ""
  }
}