Grafana
Repeat by variable
Create a variable for your dashboard
On your panel, expand "Repeat Options"
Select your variable under "Repeat by variable"
Prometheus query's
These are useful tips when using prometheus query's for tables (or any non-time series)
Query tab
Select Format "Table"
Enable Instant
Transform tab
Use Merge
Use Organize fields: great for hiding and renaming fields
Use Sort by
Elastic search query's
These are useful tips when using elastic search query's
Display the result of two queries
If you want to chart the result of two queries;
Query tab
for example: the percentage of requests by top 20 websites.
Query A: count of request Group By website
Query B: count of all requests
Expression C: $A / $B
Transform tab
Add Labels to fields
Labels: "website"
Value field name: "website"
"Per second" queries
Metric: "Bucket Script"
Variables:
count
Select "count"
Script:
params.count/$__interval_ms*1000
Last updated