danielqsj / kafka_exporter

Kafka exporter for Prometheus
Apache License 2.0
2.09k stars 602 forks source link

Error: "Templating: Failed to upgrade legacy queries" #428

Closed muzammil360 closed 3 months ago

muzammil360 commented 3 months ago

Hi @danielqsj, I am getting the error "Templating: Failed to upgrade legacy queries" when i import the dashboard using GrafanaDashboard custom resource in k8s. If i import the dashboard via GUI, it works fine. Do you know what might be going wrong here?

image
muzammil360 commented 3 months ago

Ok. i found the issue. You are using DS_PROMETHEUS_WH211 as the variable name. I need to explicitly set value to it. Here is what my CRD.

apiVersion: grafana.integreatly.org/v1beta1
kind: GrafanaDashboard
metadata:
  name: kafka
spec:
  folder: default
  instanceSelector:
    matchLabels:
      dashboards: "grafana"
  datasources:
    - inputName: "DS_PROMETHEUS_WH211"
      datasourceName: "Prometheus" 
  grafanaCom:
    id: 7589
    revision: 5
---