Skip to content

Instantly share code, notes, and snippets.

@williamzujkowski
Created November 17, 2025 05:07
Show Gist options
  • Select an option

  • Save williamzujkowski/412c4496eeda98bcfe9fc868f7aebbad to your computer and use it in GitHub Desktop.

Select an option

Save williamzujkowski/412c4496eeda98bcfe9fc868f7aebbad to your computer and use it in GitHub Desktop.
Grafana dashboard queries optimized with PromSketch
{
"dashboard": {
"title": "PromSketch Optimized Metrics",
"panels": [
{
"title": "P99 Request Latency (Optimized)",
"targets": [
{
"expr": "histogram_quantile(0.99, rate(http_request_duration_seconds_bucket[5m]))",
"datasource": "PromSketch"
}
]
},
{
"title": "CPU Usage by Pod (High-Cardinality)",
"targets": [
{
"expr": "sum(rate(container_cpu_usage_seconds_total[1h])) by (pod_name)",
"datasource": "PromSketch"
}
]
},
{
"title": "Memory Percentiles (DDSketch)",
"targets": [
{
"expr": "histogram_quantile(0.95, rate(container_memory_usage_bytes_bucket[5m]))",
"datasource": "PromSketch"
}
]
}
],
"templating": {
"list": [
{
"name": "namespace",
"query": "label_values(container_cpu_usage_seconds_total, namespace)"
}
]
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment