Grafana dashboard: Trickster
Description: Dashboard for Trickster delta cache for TSDBs

# Trickster  Grafana dashboard

> Updated to work with the latest release!

More info in [documentation](https://fusakla.github.io/trickster-grafana-dashboard/)

I made this dashboard as tool to benchmark and test [Trickster](https://github.com/Comcast/trickster) 
delta cache for time-series databases. It should speed-up loading of your frequently viewed dashboards.

This dashboard should give you good idea about how is Trickster effective in caching, it's utilization 
and possibility to observe possible impacts on time-series databases behind it (currently only Prometheus).


## Description
This dashboard uses those metric sources:
- Trickster's own metrics (for most of the important data)
- Prometheus own metrics (for observing impact on Prometheus)
- KubeStateMetrics (those are used only for resources limits display. 
This is Kubernetes specific you can override this by putting static values you use)

Every graph should have description tooltip on the upper left cornet if you hover over it.


## Requirements

### Datasource
- Prometheus datasource _(this can be directly datasource leading to Prometheus 
instance or the Trickster itself if you like recursion :)_

### Variables
To identify Trickster and Prometheus metrics dashboard needs you to specify label and it's 
value identifying their metrics. Those variables are:
- trickster_label_name - name of the label identifying Trickster metrics (e.g. `app`)
- trickster_label_value - value of the label identifying Trickster metrics (e.g. `trickster`)
- prometheus_label_name - name of the label identifying Prometheus metrics (e.g. `job`)
- prometheus_label_value - value of the label identifying Prometheus metrics (e.g. `prometheus`)

> Values can be regex matchers such as `prometheus.*`

{
  "__inputs": [
    {
      "name": "DS_PROMETHEUS",
      "label": "Prometheus",
      "description": "",
      "type": "datasource",
      "pluginId": "prometheus",
      "pluginName": "Prometheus"
    },
    {
      "name": "VAR_TRICKSTER_LABEL_NAME",
      "type": "constant",
      "label": "trickster_label_name",
      "value": "app",
      "description": ""
    },
    {
      "name": "VAR_TRICKSTER_LABEL_VALUE",
      "type": "constant",
      "label": "trickster_label_value",
      "value": "trickster",
      "description": ""
    },
    {
      "name": "VAR_PROMETHEUS_LABEL_NAME",
      "type": "constant",
      "label": "prometheus_label_name",
      "value": "job",
      "description": ""
    },
    {
      "name": "VAR_PROMETHEUS_LABEL_VALUE",
      "type": "constant",
      "label": "prometheus_label_value",
      "value": "prometheus",
      "description": ""
    }
  ],
  "__requires": [
    {
      "type": "grafana",
      "id": "grafana",
      "name": "Grafana",
      "version": "8.0.6"
    },
    {
      "type": "panel",
      "id": "heatmap",
      "name": "Heatmap",
      "version": ""
    },
    {
      "type": "panel",
      "id": "piechart",
      "name": "Pie chart",
      "version": ""
    },
    {
      "type": "datasource",
      "id": "prometheus",
      "name": "Prometheus",
      "version": "1.0.0"
    },
    {
      "type": "panel",
      "id": "stat",
      "name": "Stat",
      "version": ""
    },
    {
      "type": "panel",
      "id": "text",
      "name": "Text",
      "version": ""
    },
    {
      "type": "panel",
      "id": "timeseries",
      "name": "Time series",
      "version": ""
    }
  ],
  "annotations": {
    "list": [
      {
        "builtIn": 1,
        "datasource": "-- Grafana --",
        "enable": true,
        "hide": true,
        "iconColor": "rgba(0, 211, 255, 1)",
        "name": "Annotations & Alerts",
        "type": "dashboard"
      }
    ]
  },
  "description": "Dashboard for Trickster delta cache for TSDBs",
  "editable": true,
  "gnetId": 5756,
  "graphTooltip": 1,
  "id": null,
  "iteration": 1642009917529,
  "links": [
    {
      "icon": "question",
      "includeVars": false,
      "tags": [],
      "targetBlank": true,
      "title": "Slack",
      "tooltip": "Trickster Slack channel",
      "type": "link",
      "url": "https://gophers.slack.com/messages/trickster/"
    },
    {
      "icon": "doc",
      "tags": [],
      "targetBlank": true,
      "title": "Github",
      "tooltip": "Trickster Github repository",
      "type": "link",
      "url": "https://github.com/Comcast/trickster"
    },
    {
      "icon": "bolt",
      "tags": [],
      "targetBlank": true,
      "title": "Twitter",
      "tooltip": "Trickster Twitter wall",
      "type": "link",
      "url": "https://twitter.com/tricksterio"
    }
  ],
  "panels": [
    {
      "datasource": "${DS_PROMETHEUS}",
      "gridPos": {
        "h": 6,
        "w": 4,
        "x": 0,
        "y": 0
      },
      "id": 41,
      "links": [],
      "options": {
        "content": "<a href=\"https://github.com/trickstercache/trickster/tree/main/docs\" target=\"_blank\"><img src=\"https://i.imgur.com/uodNnPR.png\", width=\"200\", height=\"200\", style=\"position:relative;left:10%\"></img></a>",
        "mode": "html"
      },
      "pluginVersion": "8.0.6",
      "transparent": true,
      "type": "text"
    },
    {
      "cacheTimeout": null,
      "datasource": "${DS_PROMETHEUS}",
      "description": "Shows percentage of query cache hit or miss of Trickster. \nFor more info about cache success see graph info on the right.",
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "fixed"
          },
          "custom": {
            "hideFrom": {
              "legend": false,
              "tooltip": false,
              "viz": false
            }
          },
          "decimals": 0,
          "mappings": [],
          "unit": "short"
        },
        "overrides": [
          {
            "matcher": {
              "id": "byName",
              "options": "uncached"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#e7eff7",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "cached"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#336799",
                  "mode": "fixed"
                }
              }
            ]
          }
        ]
      },
      "gridPos": {
        "h": 8,
        "w": 5,
        "x": 4,
        "y": 0
      },
      "id": 45,
      "interval": null,
      "links": [],
      "maxDataPoints": 3,
      "options": {
        "displayLabels": [
          "name",
          "percent"
        ],
        "legend": {
          "calcs": [],
          "displayMode": "hidden",
          "placement": "bottom",
          "values": [
            "percent"
          ]
        },
        "pieType": "donut",
        "reduceOptions": {
          "calcs": [
            "sum"
          ],
          "fields": "",
          "values": false
        },
        "tooltip": {
          "mode": "multi"
        }
      },
      "targets": [
        {
          "datasource": "${DS_PROMETHEUS}",
          "exemplar": true,
          "expr": "sum(increase(trickster_proxy_points_total{$trickster_label_name=~\"$trickster_label_value\", instance=~\"$instance\", origin_name=~\"$origin_name\", origin_type=~\"$origin_type\"}[$aggregation_interval])) by (cache_status)",
          "format": "time_series",
          "instant": true,
          "interval": "",
          "intervalFactor": 1,
          "legendFormat": "{{ cache_status }}",
          "refId": "A"
        }
      ],
      "title": "Cache hit/miss",
      "type": "piechart"
    },
    {
      "datasource": "${DS_PROMETHEUS}",
      "description": "Shows percentage and count of queried points found of not in Trickster cache.\n\n- cached = found in cache\n- uncached = not found in cache\n\n**The more cached the better.**",
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "palette-classic"
          },
          "custom": {
            "axisLabel": "",
            "axisPlacement": "auto",
            "axisSoftMax": 1,
            "axisSoftMin": 0,
            "barAlignment": 0,
            "drawStyle": "bars",
            "fillOpacity": 0,
            "gradientMode": "none",
            "hideFrom": {
              "legend": false,
              "tooltip": false,
              "viz": false
            },
            "lineInterpolation": "linear",
            "lineWidth": 1,
            "pointSize": 5,
            "scaleDistribution": {
              "type": "linear"
            },
            "showPoints": "never",
            "spanNulls": true,
            "stacking": {
              "group": "A",
              "mode": "normal"
            },
            "thresholdsStyle": {
              "mode": "off"
            }
          },
          "links": [],
          "mappings": [],
          "max": 1,
          "min": 0,
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "green",
                "value": null
              }
            ]
          },
          "unit": "percentunit"
        },
        "overrides": [
          {
            "matcher": {
              "id": "byName",
              "options": "cached"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#336799",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "uncached"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#ffffff",
                  "mode": "fixed"
                }
              }
            ]
          }
        ]
      },
      "gridPos": {
        "h": 8,
        "w": 15,
        "x": 9,
        "y": 0
      },
      "id": 37,
      "links": [],
      "options": {
        "legend": {
          "calcs": [
            "mean",
            "lastNotNull"
          ],
          "displayMode": "table",
          "placement": "right"
        },
        "tooltip": {
          "mode": "multi"
        }
      },
      "pluginVersion": "8.0.6",
      "targets": [
        {
          "datasource": "${DS_PROMETHEUS}",
          "exemplar": true,
          "expr": "sum(increase(trickster_proxy_points_total{$trickster_label_name=~\"$trickster_label_value\", instance=~\"$instance\", origin_name=~\"$origin_name\", origin_type=~\"$origin_type\"}[$aggregation_interval])) by (cache_status)\n/ on () group_left ()\nsum(increase(trickster_proxy_points_total{$trickster_label_name=~\"$trickster_label_value\", instance=~\"$instance\", origin_name=~\"$origin_name\", origin_type=~\"$origin_type\"}[$aggregation_interval]))",
          "format": "time_series",
          "hide": false,
          "instant": false,
          "interval": "",
          "intervalFactor": 1,
          "legendFormat": "{{ cache_status }}",
          "metric": "",
          "refId": "A",
          "step": 300
        }
      ],
      "timeFrom": null,
      "timeShift": null,
      "title": "Percentage of cache hit",
      "type": "timeseries"
    },
    {
      "datasource": "${DS_PROMETHEUS}",
      "description": "How many instances are running",
      "fieldConfig": {
        "defaults": {
          "color": {
            "fixedColor": "#3d7bb6",
            "mode": "fixed"
          },
          "mappings": [
            {
              "options": {
                "match": "null",
                "result": {
                  "text": "N/A"
                }
              },
              "type": "special"
            }
          ],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "green",
                "value": null
              },
              {
                "color": "red",
                "value": 80
              }
            ]
          },
          "unit": "none"
        },
        "overrides": []
      },
      "gridPos": {
        "h": 5,
        "w": 4,
        "x": 0,
        "y": 6
      },
      "id": 1,
      "links": [],
      "maxDataPoints": 100,
      "options": {
        "colorMode": "none",
        "graphMode": "area",
        "justifyMode": "auto",
        "orientation": "horizontal",
        "reduceOptions": {
          "calcs": [
            "lastNotNull"
          ],
          "fields": "",
          "values": false
        },
        "text": {},
        "textMode": "auto"
      },
      "pluginVersion": "8.0.6",
      "targets": [
        {
          "exemplar": true,
          "expr": "count(process_start_time_seconds{$trickster_label_name=~\"$trickster_label_value\", instance=~\"$instance\"})",
          "format": "time_series",
          "instant": false,
          "interval": "",
          "intervalFactor": 1,
          "legendFormat": "",
          "refId": "A",
          "step": 900
        }
      ],
      "title": "# of Instances",
      "type": "stat"
    },
    {
      "cacheTimeout": null,
      "datasource": "${DS_PROMETHEUS}",
      "description": "Shows percentage of query cache hit or miss of Trickster. \nFor more info about cache success see graph info on the right.",
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "fixed"
          },
          "custom": {
            "hideFrom": {
              "legend": false,
              "tooltip": false,
              "viz": false
            }
          },
          "decimals": 0,
          "mappings": [],
          "unit": "short"
        },
        "overrides": [
          {
            "matcher": {
              "id": "byName",
              "options": "cached"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#336799",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "hit"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#3d7bb6",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "kmiss"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#e7eff7",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "phit"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#6398cb",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "proxy-only"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#1f78c1",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "error"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#cccccc",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "rmiss"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#9ebfdf",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "proxy-error"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#e24d42",
                  "mode": "fixed"
                }
              }
            ]
          }
        ]
      },
      "gridPos": {
        "h": 8,
        "w": 5,
        "x": 4,
        "y": 8
      },
      "id": 52,
      "interval": null,
      "links": [],
      "maxDataPoints": 3,
      "options": {
        "displayLabels": [
          "name",
          "percent"
        ],
        "legend": {
          "calcs": [],
          "displayMode": "hidden",
          "placement": "bottom",
          "values": [
            "percent"
          ]
        },
        "pieType": "donut",
        "reduceOptions": {
          "calcs": [
            "sum"
          ],
          "fields": "",
          "values": false
        },
        "tooltip": {
          "mode": "multi"
        }
      },
      "targets": [
        {
          "datasource": "${DS_PROMETHEUS}",
          "exemplar": true,
          "expr": "sum(increase(trickster_proxy_requests_total{$trickster_label_name=~\"$trickster_label_value\", instance=~\"$instance\", origin_name=~\"$origin_name\", origin_type=~\"$origin_type\"}[$aggregation_interval])) by (cache_status)",
          "format": "time_series",
          "instant": true,
          "interval": "",
          "intervalFactor": 1,
          "legendFormat": "{{ cache_status }}",
          "refId": "A"
        }
      ],
      "title": "Cache hit/miss",
      "type": "piechart"
    },
    {
      "datasource": "${DS_PROMETHEUS}",
      "description": "Shows percentage and count of queried points found of not in Trickster cache.\n\n- cached = found in cache\n- uncached = not found in cache\n\n**The more cached the better.**",
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "palette-classic"
          },
          "custom": {
            "axisLabel": "",
            "axisPlacement": "auto",
            "axisSoftMax": 1,
            "axisSoftMin": 0,
            "barAlignment": 0,
            "drawStyle": "bars",
            "fillOpacity": 0,
            "gradientMode": "none",
            "hideFrom": {
              "legend": false,
              "tooltip": false,
              "viz": false
            },
            "lineInterpolation": "linear",
            "lineWidth": 1,
            "pointSize": 5,
            "scaleDistribution": {
              "type": "linear"
            },
            "showPoints": "never",
            "spanNulls": true,
            "stacking": {
              "group": "A",
              "mode": "normal"
            },
            "thresholdsStyle": {
              "mode": "off"
            }
          },
          "links": [],
          "mappings": [],
          "max": 1,
          "min": 0,
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "green",
                "value": null
              }
            ]
          },
          "unit": "percentunit"
        },
        "overrides": [
          {
            "matcher": {
              "id": "byName",
              "options": "cached"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#336799",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "uncached"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#ffffff",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "hit"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#3d7bb6",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "error"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "red",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "rmiss"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#9ebfdf",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "kmiss"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#e7eff7",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "phit"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#6398cb",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "proxy-only"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#1f78c1",
                  "mode": "fixed"
                }
              }
            ]
          }
        ]
      },
      "gridPos": {
        "h": 8,
        "w": 15,
        "x": 9,
        "y": 8
      },
      "id": 51,
      "links": [],
      "options": {
        "legend": {
          "calcs": [
            "mean",
            "lastNotNull"
          ],
          "displayMode": "table",
          "placement": "right"
        },
        "tooltip": {
          "mode": "multi"
        }
      },
      "pluginVersion": "8.0.6",
      "targets": [
        {
          "datasource": "${DS_PROMETHEUS}",
          "exemplar": true,
          "expr": "sum(increase(trickster_proxy_requests_total{$trickster_label_name=~\"$trickster_label_value\", instance=~\"$instance\", origin_name=~\"$origin_name\", origin_type=~\"$origin_type\"}[$aggregation_interval])) by (cache_status)\n/ on () group_left()\nsum(increase(trickster_proxy_requests_total{$trickster_label_name=~\"$trickster_label_value\", instance=~\"$instance\", origin_name=~\"$origin_name\", origin_type=~\"$origin_type\"}[$aggregation_interval]))",
          "format": "time_series",
          "hide": false,
          "instant": false,
          "interval": "",
          "intervalFactor": 1,
          "legendFormat": "{{ cache_status }}",
          "metric": "",
          "refId": "A",
          "step": 300
        }
      ],
      "timeFrom": null,
      "timeShift": null,
      "title": "Percentage of cache hit",
      "type": "timeseries"
    },
    {
      "datasource": "${DS_PROMETHEUS}",
      "description": "Total count of points served",
      "fieldConfig": {
        "defaults": {
          "color": {
            "fixedColor": "#3d7bb6",
            "mode": "fixed"
          },
          "mappings": [
            {
              "options": {
                "match": "null",
                "result": {
                  "text": "N/A"
                }
              },
              "type": "special"
            }
          ],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "green",
                "value": null
              },
              {
                "color": "red",
                "value": 80
              }
            ]
          },
          "unit": "short"
        },
        "overrides": []
      },
      "gridPos": {
        "h": 5,
        "w": 4,
        "x": 0,
        "y": 11
      },
      "id": 49,
      "links": [],
      "maxDataPoints": 100,
      "options": {
        "colorMode": "none",
        "graphMode": "area",
        "justifyMode": "auto",
        "orientation": "horizontal",
        "reduceOptions": {
          "calcs": [
            "sum"
          ],
          "fields": "",
          "values": false
        },
        "text": {},
        "textMode": "auto"
      },
      "pluginVersion": "8.0.6",
      "targets": [
        {
          "datasource": "${DS_PROMETHEUS}",
          "exemplar": true,
          "expr": "sum(increase(trickster_proxy_points_total{$trickster_label_name=~\"$trickster_label_value\", instance=~\"$instance\", origin_name=~\"$origin_name\", origin_type=~\"$origin_type\"}[$aggregation_interval]))",
          "format": "time_series",
          "instant": false,
          "interval": "",
          "intervalFactor": 1,
          "legendFormat": "",
          "refId": "A",
          "step": 900
        }
      ],
      "title": "# of served points",
      "type": "stat"
    },
    {
      "datasource": "${DS_PROMETHEUS}",
      "description": "Total count of requests aggregated by instance.\nShows how are the requests balanced.",
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "palette-classic"
          },
          "custom": {
            "axisLabel": "",
            "axisPlacement": "auto",
            "barAlignment": 0,
            "drawStyle": "line",
            "fillOpacity": 40,
            "gradientMode": "none",
            "hideFrom": {
              "legend": false,
              "tooltip": false,
              "viz": false
            },
            "lineInterpolation": "linear",
            "lineWidth": 1,
            "pointSize": 5,
            "scaleDistribution": {
              "type": "linear"
            },
            "showPoints": "never",
            "spanNulls": true,
            "stacking": {
              "group": "A",
              "mode": "normal"
            },
            "thresholdsStyle": {
              "mode": "off"
            }
          },
          "links": [],
          "mappings": [],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "green",
                "value": null
              },
              {
                "color": "red",
                "value": 80
              }
            ]
          },
          "unit": "short"
        },
        "overrides": [
          {
            "matcher": {
              "id": "byName",
              "options": "404"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#EAB839",
                  "mode": "fixed"
                }
              }
            ]
          }
        ]
      },
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 0,
        "y": 16
      },
      "id": 7,
      "links": [],
      "options": {
        "legend": {
          "calcs": [],
          "displayMode": "list",
          "placement": "bottom"
        },
        "tooltip": {
          "mode": "multi"
        }
      },
      "pluginVersion": "8.0.6",
      "targets": [
        {
          "datasource": "${DS_PROMETHEUS}",
          "exemplar": true,
          "expr": "sum(increase(trickster_proxy_requests_total{$trickster_label_name=~\"$trickster_label_value\", instance=~\"$instance\", origin_name=~\"$origin_name\", origin_type=~\"$origin_type\"}[$aggregation_interval])) by (instance)",
          "format": "time_series",
          "interval": "",
          "intervalFactor": 1,
          "legendFormat": "{{ instance }}",
          "metric": "",
          "refId": "A",
          "step": 300
        },
        {
          "datasource": "${DS_PROMETHEUS}",
          "exemplar": true,
          "expr": "sum(increase(trickster_proxy_requests_total{$trickster_label_name=~\"$trickster_label_value\", instance=~\"$instance\", origin_name=~\"$origin_name\", origin_type=~\"$origin_type\"}[$aggregation_interval]))",
          "format": "time_series",
          "interval": "",
          "intervalFactor": 1,
          "legendFormat": "total",
          "refId": "B",
          "step": 300
        }
      ],
      "timeFrom": null,
      "timeShift": null,
      "title": "Total requests by instance",
      "type": "timeseries"
    },
    {
      "cards": {
        "cardPadding": 0,
        "cardRound": 0
      },
      "color": {
        "cardColor": "#b4ff00",
        "colorScale": "sqrt",
        "colorScheme": "interpolateBlues",
        "exponent": 0.5,
        "mode": "spectrum"
      },
      "dataFormat": "tsbuckets",
      "datasource": "${DS_PROMETHEUS}",
      "description": "Shows how long the requests took to be served as histogram using quantiles. This means that x% was served faster than the value of the metric.\nThat means:\n- 50%: shows time before 50% of requests was served\n- 90%: shows time before 90% of requests was served\n- 99%: shows time before 99% of requests was served",
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 12,
        "y": 16
      },
      "heatmap": {},
      "hideZeroBuckets": true,
      "highlightCards": true,
      "id": 16,
      "legend": {
        "show": true
      },
      "links": [],
      "pluginVersion": "8.3.3",
      "reverseYBuckets": false,
      "targets": [
        {
          "datasource": "${DS_PROMETHEUS}",
          "exemplar": true,
          "expr": "sum(rate(trickster_proxy_request_duration_seconds_bucket{$trickster_label_name=~\"$trickster_label_value\", instance=~\"$instance\", origin_name=~\"$origin_name\", origin_type=~\"$origin_type\"}[$aggregation_interval])) by (le)",
          "format": "heatmap",
          "hide": false,
          "instant": false,
          "interval": "2m",
          "intervalFactor": 1,
          "legendFormat": "{{le}}",
          "refId": "E"
        }
      ],
      "title": "Proxy request duration",
      "tooltip": {
        "show": true,
        "showHistogram": true
      },
      "type": "heatmap",
      "xAxis": {
        "show": true
      },
      "xBucketNumber": null,
      "xBucketSize": null,
      "yAxis": {
        "decimals": null,
        "format": "s",
        "logBase": 1,
        "max": null,
        "min": null,
        "show": true,
        "splitFactor": null
      },
      "yBucketBound": "auto",
      "yBucketNumber": null,
      "yBucketSize": null
    },
    {
      "datasource": "${DS_PROMETHEUS}",
      "description": "Shows total query count aggregated by type.\nThere are two types;\n- query: instant query resulting in data in given time\n- query_range: query for data in given time interval",
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "palette-classic"
          },
          "custom": {
            "axisLabel": "",
            "axisPlacement": "auto",
            "barAlignment": 0,
            "drawStyle": "line",
            "fillOpacity": 40,
            "gradientMode": "none",
            "hideFrom": {
              "legend": false,
              "tooltip": false,
              "viz": false
            },
            "lineInterpolation": "linear",
            "lineWidth": 1,
            "pointSize": 5,
            "scaleDistribution": {
              "type": "linear"
            },
            "showPoints": "never",
            "spanNulls": true,
            "stacking": {
              "group": "A",
              "mode": "normal"
            },
            "thresholdsStyle": {
              "mode": "off"
            }
          },
          "links": [],
          "mappings": [],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "green",
                "value": null
              },
              {
                "color": "red",
                "value": 80
              }
            ]
          },
          "unit": "short"
        },
        "overrides": []
      },
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 0,
        "y": 23
      },
      "id": 26,
      "links": [],
      "options": {
        "legend": {
          "calcs": [],
          "displayMode": "list",
          "placement": "bottom"
        },
        "tooltip": {
          "mode": "multi"
        }
      },
      "pluginVersion": "8.0.6",
      "targets": [
        {
          "datasource": "${DS_PROMETHEUS}",
          "exemplar": true,
          "expr": "sum(increase(trickster_proxy_requests_total{$trickster_label_name=~\"$trickster_label_value\", instance=~\"$instance\", origin_name=~\"$origin_name\", origin_type=~\"$origin_type\"}[$aggregation_interval])) by (method)",
          "format": "time_series",
          "interval": "",
          "intervalFactor": 1,
          "legendFormat": "{{ method }}",
          "metric": "",
          "refId": "A",
          "step": 300
        },
        {
          "datasource": "${DS_PROMETHEUS}",
          "exemplar": true,
          "expr": "sum(increase(trickster_proxy_requests_total{$trickster_label_name=~\"$trickster_label_value\", instance=~\"$instance\", origin_name=~\"$origin_name\", origin_type=~\"$origin_type\"}[$aggregation_interval]))",
          "format": "time_series",
          "interval": "",
          "intervalFactor": 1,
          "legendFormat": "total",
          "refId": "B",
          "step": 300
        }
      ],
      "timeFrom": null,
      "timeShift": null,
      "title": "Total requests by type",
      "type": "timeseries"
    },
    {
      "datasource": "${DS_PROMETHEUS}",
      "description": "Shows total query count aggregated by type.\nThere are two types;\n- query: instant query resulting in data in given time\n- query_range: query for data in given time interval",
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "palette-classic"
          },
          "custom": {
            "axisLabel": "",
            "axisPlacement": "auto",
            "barAlignment": 0,
            "drawStyle": "line",
            "fillOpacity": 40,
            "gradientMode": "none",
            "hideFrom": {
              "legend": false,
              "tooltip": false,
              "viz": false
            },
            "lineInterpolation": "linear",
            "lineWidth": 1,
            "pointSize": 5,
            "scaleDistribution": {
              "type": "linear"
            },
            "showPoints": "never",
            "spanNulls": true,
            "stacking": {
              "group": "A",
              "mode": "normal"
            },
            "thresholdsStyle": {
              "mode": "off"
            }
          },
          "links": [],
          "mappings": [],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "green",
                "value": null
              },
              {
                "color": "red",
                "value": 80
              }
            ]
          },
          "unit": "short"
        },
        "overrides": [
          {
            "matcher": {
              "id": "byName",
              "options": "404"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#EAB839",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "408"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#EF843C",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "500"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#890F02",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "method endpoint"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#E0F9D7",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "query"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#fceaca",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "query_range"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#cca300",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "total"
            },
            "properties": [
              {
                "id": "custom.lineWidth",
                "value": 0
              },
              {
                "id": "custom.stacking",
                "value": {
                  "group": false,
                  "mode": "normal"
                }
              }
            ]
          }
        ]
      },
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 12,
        "y": 23
      },
      "id": 50,
      "links": [],
      "options": {
        "legend": {
          "calcs": [],
          "displayMode": "list",
          "placement": "bottom"
        },
        "tooltip": {
          "mode": "multi"
        }
      },
      "pluginVersion": "8.0.6",
      "targets": [
        {
          "datasource": "${DS_PROMETHEUS}",
          "exemplar": true,
          "expr": "sum(increase(trickster_proxy_requests_total{$trickster_label_name=~\"$trickster_label_value\", instance=~\"$instance\", origin_name=~\"$origin_name\", origin_type=~\"$origin_type\"}[$aggregation_interval])) by (origin_name, origin_type)",
          "format": "time_series",
          "interval": "",
          "intervalFactor": 1,
          "legendFormat": "{{ origin_type }}: {{origin_name}}",
          "metric": "",
          "refId": "A",
          "step": 300
        }
      ],
      "timeFrom": null,
      "timeShift": null,
      "title": "Total requests by type",
      "type": "timeseries"
    },
    {
      "collapsed": false,
      "datasource": "${DS_PROMETHEUS}",
      "gridPos": {
        "h": 1,
        "w": 24,
        "x": 0,
        "y": 30
      },
      "id": 21,
      "panels": [],
      "title": "Trickster performance data",
      "type": "row"
    },
    {
      "datasource": "${DS_PROMETHEUS}",
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "palette-classic"
          },
          "custom": {
            "axisLabel": "",
            "axisPlacement": "auto",
            "barAlignment": 0,
            "drawStyle": "line",
            "fillOpacity": 10,
            "gradientMode": "none",
            "hideFrom": {
              "legend": false,
              "tooltip": false,
              "viz": false
            },
            "lineInterpolation": "linear",
            "lineWidth": 1,
            "pointSize": 5,
            "scaleDistribution": {
              "type": "linear"
            },
            "showPoints": "never",
            "spanNulls": false,
            "stacking": {
              "group": "A",
              "mode": "none"
            },
            "thresholdsStyle": {
              "mode": "off"
            }
          },
          "links": [],
          "mappings": [],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "green",
                "value": null
              },
              {
                "color": "red",
                "value": 80
              }
            ]
          },
          "unit": "short"
        },
        "overrides": [
          {
            "matcher": {
              "id": "byRegexp",
              "options": "/Limit .*/"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#C15C17",
                  "mode": "fixed"
                }
              },
              {
                "id": "custom.fillOpacity",
                "value": 0
              },
              {
                "id": "custom.lineStyle",
                "value": {
                  "dash": [
                    10,
                    10
                  ],
                  "fill": "dash"
                }
              }
            ]
          }
        ]
      },
      "gridPos": {
        "h": 7,
        "w": 13,
        "x": 0,
        "y": 31
      },
      "id": 8,
      "links": [],
      "options": {
        "legend": {
          "calcs": [],
          "displayMode": "hidden",
          "placement": "bottom"
        },
        "tooltip": {
          "mode": "single"
        }
      },
      "pluginVersion": "8.0.6",
      "targets": [
        {
          "datasource": "${DS_PROMETHEUS}",
          "exemplar": true,
          "expr": "rate(process_cpu_seconds_total{$trickster_label_name=~\"$trickster_label_value\", instance=~\"$instance\"}[$aggregation_interval])",
          "format": "time_series",
          "groupBy": [
            {
              "params": [
                "$__interval"
              ],
              "type": "time"
            },
            {
              "params": [
                "null"
              ],
              "type": "fill"
            }
          ],
          "interval": "",
          "intervalFactor": 1,
          "legendFormat": "{{instance}}",
          "orderByTime": "ASC",
          "policy": "default",
          "refId": "A",
          "resultFormat": "time_series",
          "select": [
            [
              {
                "params": [
                  "value"
                ],
                "type": "field"
              },
              {
                "params": [],
                "type": "mean"
              }
            ]
          ],
          "tags": []
        },
        {
          "datasource": "${DS_PROMETHEUS}",
          "expr": "max(kube_pod_container_resource_limits_cpu_cores{container=\"trickster\", pod=~\"$instance\"}) by (instance)",
          "format": "time_series",
          "intervalFactor": 1,
          "legendFormat": "Limit {{instance}}",
          "refId": "B"
        }
      ],
      "timeFrom": null,
      "timeShift": null,
      "title": "CPU usage/s",
      "type": "timeseries"
    },
    {
      "datasource": "${DS_PROMETHEUS}",
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "palette-classic"
          },
          "custom": {
            "axisLabel": "",
            "axisPlacement": "auto",
            "barAlignment": 0,
            "drawStyle": "line",
            "fillOpacity": 10,
            "gradientMode": "none",
            "hideFrom": {
              "legend": false,
              "tooltip": false,
              "viz": false
            },
            "lineInterpolation": "linear",
            "lineWidth": 1,
            "pointSize": 5,
            "scaleDistribution": {
              "type": "linear"
            },
            "showPoints": "never",
            "spanNulls": false,
            "stacking": {
              "group": "A",
              "mode": "none"
            },
            "thresholdsStyle": {
              "mode": "off"
            }
          },
          "links": [],
          "mappings": [],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "green",
                "value": null
              },
              {
                "color": "red",
                "value": 80
              }
            ]
          },
          "unit": "bytes"
        },
        "overrides": [
          {
            "matcher": {
              "id": "byRegexp",
              "options": "/Limit .*/"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#C15C17",
                  "mode": "fixed"
                }
              },
              {
                "id": "custom.fillOpacity",
                "value": 0
              },
              {
                "id": "custom.lineStyle",
                "value": {
                  "dash": [
                    10,
                    10
                  ],
                  "fill": "dash"
                }
              }
            ]
          }
        ]
      },
      "gridPos": {
        "h": 7,
        "w": 11,
        "x": 13,
        "y": 31
      },
      "id": 47,
      "links": [],
      "options": {
        "legend": {
          "calcs": [],
          "displayMode": "hidden",
          "placement": "bottom"
        },
        "tooltip": {
          "mode": "single"
        }
      },
      "pluginVersion": "8.0.6",
      "targets": [
        {
          "datasource": "${DS_PROMETHEUS}",
          "exemplar": true,
          "expr": "process_resident_memory_bytes{$trickster_label_name=~\"$trickster_label_value\", instance=~\"$instance\"}",
          "format": "time_series",
          "hide": false,
          "interval": "",
          "intervalFactor": 1,
          "legendFormat": "{{ instance }}",
          "refId": "E"
        },
        {
          "datasource": "${DS_PROMETHEUS}",
          "exemplar": true,
          "expr": "max(kube_pod_container_resource_limits_memory_bytes{container=\"trickster\", pod=~\"$instance\"}) by (pod)",
          "format": "time_series",
          "hide": false,
          "interval": "",
          "intervalFactor": 1,
          "legendFormat": "Limit {{ pod }}",
          "refId": "A"
        }
      ],
      "timeFrom": null,
      "timeShift": null,
      "title": "Memory usage",
      "type": "timeseries"
    },
    {
      "collapsed": false,
      "datasource": "${DS_PROMETHEUS}",
      "gridPos": {
        "h": 1,
        "w": 24,
        "x": 0,
        "y": 38
      },
      "id": 34,
      "panels": [],
      "title": "Prometheus performance data",
      "type": "row"
    },
    {
      "datasource": "${DS_PROMETHEUS}",
      "description": "This shows how long did it take  Prometheus to server requests.\nThis could be possibly lower time when using Trickster since the queries can be for smaller more recent time range.",
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "palette-classic"
          },
          "custom": {
            "axisLabel": "",
            "axisPlacement": "auto",
            "barAlignment": 0,
            "drawStyle": "line",
            "fillOpacity": 10,
            "gradientMode": "none",
            "hideFrom": {
              "legend": false,
              "tooltip": false,
              "viz": false
            },
            "lineInterpolation": "linear",
            "lineWidth": 1,
            "pointSize": 5,
            "scaleDistribution": {
              "type": "linear"
            },
            "showPoints": "never",
            "spanNulls": true,
            "stacking": {
              "group": "A",
              "mode": "normal"
            },
            "thresholdsStyle": {
              "mode": "off"
            }
          },
          "links": [],
          "mappings": [],
          "min": 0,
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "green",
                "value": null
              },
              {
                "color": "red",
                "value": 80
              }
            ]
          },
          "unit": "s"
        },
        "overrides": []
      },
      "gridPos": {
        "h": 7,
        "w": 8,
        "x": 0,
        "y": 39
      },
      "id": 29,
      "links": [],
      "options": {
        "legend": {
          "calcs": [
            "mean"
          ],
          "displayMode": "hidden",
          "placement": "bottom"
        },
        "tooltip": {
          "mode": "single"
        }
      },
      "pluginVersion": "8.0.6",
      "targets": [
        {
          "exemplar": true,
          "expr": "max(prometheus_engine_query_duration_seconds{$prometheus_label_name=~\"$prometheus_label_value\"}) by (instance, slice)",
          "format": "time_series",
          "interval": "",
          "intervalFactor": 1,
          "legendFormat": "{{ slice }} {{ instance }}",
          "metric": "prometheus_local_storage_rushed_mode",
          "refId": "A",
          "step": 900
        }
      ],
      "timeFrom": null,
      "timeShift": null,
      "title": "Prometheus Query elapsed time",
      "type": "timeseries"
    },
    {
      "datasource": "${DS_PROMETHEUS}",
      "description": "Shows total request count on Prometheus server.",
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "palette-classic"
          },
          "custom": {
            "axisLabel": "",
            "axisPlacement": "auto",
            "barAlignment": 0,
            "drawStyle": "line",
            "fillOpacity": 10,
            "gradientMode": "none",
            "hideFrom": {
              "legend": false,
              "tooltip": false,
              "viz": false
            },
            "lineInterpolation": "linear",
            "lineWidth": 1,
            "pointSize": 5,
            "scaleDistribution": {
              "type": "linear"
            },
            "showPoints": "never",
            "spanNulls": true,
            "stacking": {
              "group": "A",
              "mode": "normal"
            },
            "thresholdsStyle": {
              "mode": "off"
            }
          },
          "links": [],
          "mappings": [],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "green",
                "value": null
              },
              {
                "color": "red",
                "value": 80
              }
            ]
          },
          "unit": "none"
        },
        "overrides": [
          {
            "matcher": {
              "id": "byName",
              "options": "Chunks"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#1F78C1",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "Chunks to persist"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#508642",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "Max chunks"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#052B51",
                  "mode": "fixed"
                }
              }
            ]
          },
          {
            "matcher": {
              "id": "byName",
              "options": "Max to persist"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#3F6833",
                  "mode": "fixed"
                }
              }
            ]
          }
        ]
      },
      "gridPos": {
        "h": 7,
        "w": 8,
        "x": 8,
        "y": 39
      },
      "id": 31,
      "links": [],
      "options": {
        "legend": {
          "calcs": [],
          "displayMode": "hidden",
          "placement": "bottom"
        },
        "tooltip": {
          "mode": "single"
        }
      },
      "pluginVersion": "8.0.6",
      "targets": [
        {
          "datasource": "${DS_PROMETHEUS}",
          "exemplar": true,
          "expr": "sum(increase(prometheus_http_requests_total{$prometheus_label_name=~\"$prometheus_label_value\"}[$aggregation_interval])) by (instance, handler) > 0",
          "format": "time_series",
          "interval": "",
          "intervalFactor": 1,
          "legendFormat": "{{ handler }} on {{ instance }}",
          "metric": "",
          "refId": "A",
          "step": 1800
        }
      ],
      "timeFrom": null,
      "timeShift": null,
      "title": "Prometheus Request count",
      "type": "timeseries"
    },
    {
      "cards": {
        "cardPadding": 0,
        "cardRound": 0
      },
      "color": {
        "cardColor": "#b4ff00",
        "colorScale": "sqrt",
        "colorScheme": "interpolateBlues",
        "exponent": 0.5,
        "mode": "spectrum"
      },
      "dataFormat": "tsbuckets",
      "datasource": "${DS_PROMETHEUS}",
      "description": "Shows duration how long it takes to Prometheus to server requests aggregated by handlers",
      "gridPos": {
        "h": 7,
        "w": 8,
        "x": 16,
        "y": 39
      },
      "heatmap": {},
      "hideZeroBuckets": false,
      "highlightCards": true,
      "id": 32,
      "legend": {
        "show": true
      },
      "links": [],
      "pluginVersion": "8.3.3",
      "reverseYBuckets": false,
      "targets": [
        {
          "datasource": "${DS_PROMETHEUS}",
          "exemplar": true,
          "expr": "sum(rate(prometheus_http_request_duration_seconds_bucket{$prometheus_label_name=~\"$prometheus_label_value\"}[$aggregation_interval])) by (le)",
          "format": "heatmap",
          "hide": false,
          "interval": "2m",
          "intervalFactor": 1,
          "legendFormat": "{{le}}",
          "refId": "C"
        }
      ],
      "title": "Prometheus request duration histogram",
      "tooltip": {
        "show": true,
        "showHistogram": true
      },
      "type": "heatmap",
      "xAxis": {
        "show": true
      },
      "xBucketNumber": null,
      "xBucketSize": null,
      "yAxis": {
        "decimals": null,
        "format": "s",
        "logBase": 1,
        "max": null,
        "min": null,
        "show": true,
        "splitFactor": null
      },
      "yBucketBound": "auto",
      "yBucketNumber": null,
      "yBucketSize": null
    },
    {
      "datasource": "${DS_PROMETHEUS}",
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "palette-classic"
          },
          "custom": {
            "axisLabel": "",
            "axisPlacement": "auto",
            "barAlignment": 0,
            "drawStyle": "line",
            "fillOpacity": 10,
            "gradientMode": "none",
            "hideFrom": {
              "legend": false,
              "tooltip": false,
              "viz": false
            },
            "lineInterpolation": "linear",
            "lineWidth": 1,
            "pointSize": 5,
            "scaleDistribution": {
              "type": "linear"
            },
            "showPoints": "never",
            "spanNulls": false,
            "stacking": {
              "group": "A",
              "mode": "none"
            },
            "thresholdsStyle": {
              "mode": "off"
            }
          },
          "links": [],
          "mappings": [],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "green",
                "value": null
              },
              {
                "color": "red",
                "value": 80
              }
            ]
          },
          "unit": "short"
        },
        "overrides": [
          {
            "matcher": {
              "id": "byRegexp",
              "options": "/Limit .*/"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#890f02",
                  "mode": "fixed"
                }
              },
              {
                "id": "custom.fillOpacity",
                "value": 0
              },
              {
                "id": "custom.lineWidth",
                "value": 2
              },
              {
                "id": "custom.lineStyle",
                "value": {
                  "dash": [
                    10,
                    10
                  ],
                  "fill": "dash"
                }
              }
            ]
          }
        ]
      },
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 0,
        "y": 46
      },
      "id": 48,
      "links": [],
      "options": {
        "legend": {
          "calcs": [],
          "displayMode": "hidden",
          "placement": "bottom"
        },
        "tooltip": {
          "mode": "single"
        }
      },
      "pluginVersion": "8.0.6",
      "targets": [
        {
          "datasource": "${DS_PROMETHEUS}",
          "exemplar": true,
          "expr": "rate(process_cpu_seconds_total{$prometheus_label_name=~\"$prometheus_label_value\"}[$aggregation_interval])",
          "format": "time_series",
          "interval": "",
          "intervalFactor": 1,
          "legendFormat": "{{ instance }}",
          "refId": "A"
        },
        {
          "datasource": "${DS_PROMETHEUS}",
          "expr": "max(kube_pod_container_resource_limits_cpu_cores{container=\"prometheus\"}) by (pod)",
          "format": "time_series",
          "intervalFactor": 1,
          "legendFormat": "Limit {{pod}}",
          "refId": "B"
        }
      ],
      "timeFrom": null,
      "timeShift": null,
      "title": "CPU usage/s",
      "type": "timeseries"
    },
    {
      "datasource": "${DS_PROMETHEUS}",
      "fieldConfig": {
        "defaults": {
          "color": {
            "mode": "palette-classic"
          },
          "custom": {
            "axisLabel": "",
            "axisPlacement": "auto",
            "barAlignment": 0,
            "drawStyle": "line",
            "fillOpacity": 10,
            "gradientMode": "none",
            "hideFrom": {
              "legend": false,
              "tooltip": false,
              "viz": false
            },
            "lineInterpolation": "linear",
            "lineWidth": 1,
            "pointSize": 5,
            "scaleDistribution": {
              "type": "linear"
            },
            "showPoints": "never",
            "spanNulls": false,
            "stacking": {
              "group": "A",
              "mode": "none"
            },
            "thresholdsStyle": {
              "mode": "off"
            }
          },
          "links": [],
          "mappings": [],
          "thresholds": {
            "mode": "absolute",
            "steps": [
              {
                "color": "green",
                "value": null
              },
              {
                "color": "red",
                "value": 80
              }
            ]
          },
          "unit": "decbytes"
        },
        "overrides": [
          {
            "matcher": {
              "id": "byRegexp",
              "options": "/Limit .*/"
            },
            "properties": [
              {
                "id": "color",
                "value": {
                  "fixedColor": "#890f02",
                  "mode": "fixed"
                }
              },
              {
                "id": "custom.fillOpacity",
                "value": 0
              },
              {
                "id": "custom.lineWidth",
                "value": 2
              },
              {
                "id": "custom.lineStyle",
                "value": {
                  "dash": [
                    10,
                    10
                  ],
                  "fill": "dash"
                }
              }
            ]
          }
        ]
      },
      "gridPos": {
        "h": 7,
        "w": 12,
        "x": 12,
        "y": 46
      },
      "id": 35,
      "links": [],
      "options": {
        "legend": {
          "calcs": [],
          "displayMode": "hidden",
          "placement": "bottom"
        },
        "tooltip": {
          "mode": "single"
        }
      },
      "pluginVersion": "8.0.6",
      "targets": [
        {
          "datasource": "${DS_PROMETHEUS}",
          "exemplar": true,
          "expr": "process_resident_memory_bytes{$prometheus_label_name=~\"$prometheus_label_value\"}",
          "format": "time_series",
          "interval": "",
          "intervalFactor": 1,
          "legendFormat": "{{ instance }}",
          "refId": "A"
        },
        {
          "datasource": "${DS_PROMETHEUS}",
          "expr": "max(kube_pod_container_resource_limits_memory_bytes{container=\"prometheus\"}) by (pod)",
          "format": "time_series",
          "intervalFactor": 1,
          "legendFormat": "Limit {{pod}}",
          "refId": "B"
        }
      ],
      "timeFrom": null,
      "timeShift": null,
      "title": "Memory usage",
      "type": "timeseries"
    }
  ],
  "refresh": false,
  "schemaVersion": 30,
  "style": "dark",
  "tags": [
    "prometheus",
    "trickster",
    "monitoring"
  ],
  "templating": {
    "list": [
      {
        "current": {
          "selected": false,
          "text": "Prometheus",
          "value": "Prometheus"
        },
        "description": null,
        "error": null,
        "hide": 0,
        "includeAll": false,
        "label": null,
        "multi": false,
        "name": "Datasource",
        "options": [],
        "query": "prometheus",
        "refresh": 1,
        "regex": "",
        "skipUrlSync": false,
        "type": "datasource"
      },
      {
        "description": null,
        "error": null,
        "hide": 2,
        "label": null,
        "name": "trickster_label_name",
        "query": "${VAR_TRICKSTER_LABEL_NAME}",
        "skipUrlSync": false,
        "type": "constant",
        "current": {
          "value": "${VAR_TRICKSTER_LABEL_NAME}",
          "text": "${VAR_TRICKSTER_LABEL_NAME}",
          "selected": false
        },
        "options": [
          {
            "value": "${VAR_TRICKSTER_LABEL_NAME}",
            "text": "${VAR_TRICKSTER_LABEL_NAME}",
            "selected": false
          }
        ]
      },
      {
        "description": null,
        "error": null,
        "hide": 2,
        "label": null,
        "name": "trickster_label_value",
        "query": "${VAR_TRICKSTER_LABEL_VALUE}",
        "skipUrlSync": false,
        "type": "constant",
        "current": {
          "value": "${VAR_TRICKSTER_LABEL_VALUE}",
          "text": "${VAR_TRICKSTER_LABEL_VALUE}",
          "selected": false
        },
        "options": [
          {
            "value": "${VAR_TRICKSTER_LABEL_VALUE}",
            "text": "${VAR_TRICKSTER_LABEL_VALUE}",
            "selected": false
          }
        ]
      },
      {
        "description": null,
        "error": null,
        "hide": 2,
        "label": null,
        "name": "prometheus_label_name",
        "query": "${VAR_PROMETHEUS_LABEL_NAME}",
        "skipUrlSync": false,
        "type": "constant",
        "current": {
          "value": "${VAR_PROMETHEUS_LABEL_NAME}",
          "text": "${VAR_PROMETHEUS_LABEL_NAME}",
          "selected": false
        },
        "options": [
          {
            "value": "${VAR_PROMETHEUS_LABEL_NAME}",
            "text": "${VAR_PROMETHEUS_LABEL_NAME}",
            "selected": false
          }
        ]
      },
      {
        "description": null,
        "error": null,
        "hide": 2,
        "label": null,
        "name": "prometheus_label_value",
        "query": "${VAR_PROMETHEUS_LABEL_VALUE}",
        "skipUrlSync": false,
        "type": "constant",
        "current": {
          "value": "${VAR_PROMETHEUS_LABEL_VALUE}",
          "text": "${VAR_PROMETHEUS_LABEL_VALUE}",
          "selected": false
        },
        "options": [
          {
            "value": "${VAR_PROMETHEUS_LABEL_VALUE}",
            "text": "${VAR_PROMETHEUS_LABEL_VALUE}",
            "selected": false
          }
        ]
      },
      {
        "allValue": ".*",
        "current": {},
        "datasource": "${DS_PROMETHEUS}",
        "definition": "",
        "description": null,
        "error": null,
        "hide": 0,
        "includeAll": true,
        "label": "Instance",
        "multi": true,
        "name": "instance",
        "options": [],
        "query": {
          "query": "label_values(process_start_time_seconds{$trickster_label_name=~\"$trickster_label_value\"}, instance)",
          "refId": "Trickster (Prometheus proxy)-instance-Variable-Query"
        },
        "refresh": 2,
        "regex": "",
        "skipUrlSync": false,
        "sort": 1,
        "tagValuesQuery": "",
        "tagsQuery": "",
        "type": "query",
        "useTags": false
      },
      {
        "auto": true,
        "auto_count": 100,
        "auto_min": "2m",
        "current": {
          "selected": false,
          "text": "auto",
          "value": "$__auto_interval_aggregation_interval"
        },
        "description": null,
        "error": null,
        "hide": 0,
        "label": "Aggregation interval",
        "name": "aggregation_interval",
        "options": [
          {
            "selected": true,
            "text": "auto",
            "value": "$__auto_interval_aggregation_interval"
          },
          {
            "selected": false,
            "text": "1m",
            "value": "1m"
          },
          {
            "selected": false,
            "text": "2m",
            "value": "2m"
          },
          {
            "selected": false,
            "text": "3m",
            "value": "3m"
          },
          {
            "selected": false,
            "text": "5m",
            "value": "5m"
          },
          {
            "selected": false,
            "text": "10m",
            "value": "10m"
          },
          {
            "selected": false,
            "text": "15m",
            "value": "15m"
          },
          {
            "selected": false,
            "text": "30m",
            "value": "30m"
          },
          {
            "selected": false,
            "text": "1h",
            "value": "1h"
          },
          {
            "selected": false,
            "text": "6h",
            "value": "6h"
          },
          {
            "selected": false,
            "text": "1d",
            "value": "1d"
          }
        ],
        "query": "1m,2m,3m,5m,10m,15m,30m,1h,6h,1d",
        "queryValue": "",
        "refresh": 2,
        "skipUrlSync": false,
        "type": "interval"
      },
      {
        "allValue": ".*",
        "current": {},
        "datasource": "${DS_PROMETHEUS}",
        "definition": "label_values(trickster_proxy_requests_total{instance=~\"$instance\"},origin_name)",
        "description": null,
        "error": null,
        "hide": 0,
        "includeAll": true,
        "label": null,
        "multi": true,
        "name": "origin_name",
        "options": [],
        "query": {
          "query": "label_values(trickster_proxy_requests_total{instance=~\"$instance\"},origin_name)",
          "refId": "StandardVariableQuery"
        },
        "refresh": 2,
        "regex": "",
        "skipUrlSync": false,
        "sort": 1,
        "type": "query"
      },
      {
        "allValue": ".*",
        "current": {},
        "datasource": "${DS_PROMETHEUS}",
        "definition": "label_values(trickster_proxy_requests_total{instance=~\"$instance\"},origin_type)",
        "description": null,
        "error": null,
        "hide": 0,
        "includeAll": true,
        "label": null,
        "multi": true,
        "name": "origin_type",
        "options": [],
        "query": {
          "query": "label_values(trickster_proxy_requests_total{instance=~\"$instance\"},origin_type)",
          "refId": "StandardVariableQuery"
        },
        "refresh": 2,
        "regex": "",
        "skipUrlSync": false,
        "sort": 1,
        "type": "query"
      }
    ]
  },
  "time": {
    "from": "now-6h",
    "to": "now"
  },
  "timepicker": {
    "nowDelay": "",
    "refresh_intervals": [
      "10s",
      "30s",
      "1m",
      "5m",
      "15m",
      "30m",
      "1h",
      "2h",
      "1d"
    ],
    "time_options": [
      "5m",
      "15m",
      "1h",
      "6h",
      "12h",
      "24h",
      "2d",
      "7d",
      "30d"
    ]
  },
  "timezone": "",
  "title": "Trickster",
  "uid": "Y2RsNOJ7kw66",
  "version": 2
}