Loading...
Loading...
Grafana Professional Services tool for identifying which Prometheus metrics drive high Data Points per Minute (DPM). Analyzes metric-level DPM with per-label breakdown to help optimize Grafana Cloud costs. Use when the user asks about DPM analysis, high-cardinality metrics, metric cost optimization, finding noisy metrics, or running dpm-finder against a Grafana Cloud Prometheus endpoint.
npx skill4agent add grafana/skills dpm-findergit clone https://github.com/grafana-ps/dpm-finder.git
cd dpm-finder
python3 -m venv venv
source venv/bin/activate
pip install -r requirements.txt.env_example.envPROMETHEUS_ENDPOINT.netPROMETHEUS_USERNAMEPROMETHEUS_API_KEYglc_...gcx config check # Show active stack context
gcx config list-contexts # List all configured stacks
gcx config view # Full config with endpointshttps://prometheus-{cluster_slug}.grafana.netgrafanacloud_instance_info{name=~"STACK_NAME.*"}cluster_slugid./dpm-finder.py -f json -m 2.0 -t 8 --timeout 120 -l 10| Flag | Default | Description |
|---|---|---|
| | Output format: |
| | Minimum DPM threshold to include a metric |
| | Concurrent processing threads |
| | Lookback window in minutes for DPM calculation |
| | API request timeout in seconds |
| (none) | Dollar cost per 1000 series; adds estimated_cost column |
| | Suppress progress output |
| | Enable debug logging |
| | Run as Prometheus exporter instead of one-shot |
| | Exporter server port |
| | Exporter metric refresh interval in seconds |
-f jsonmetric_rates.jsonmetrics[].metric_namemetrics[].dpmmetrics[].series_countmetrics[].series_detail[]total_metrics_above_thresholdperformance_metrics.total_runtime_secondsperformance_metrics.average_metric_processing_secondsperformance_metrics.total_metrics_processedperformance_metrics.metrics_per_second-f csvmetric_rates.csvmetric_namedpmseries_countestimated_cost--cost-per-1000-series-f textmetric_rates.txt-f prommetric_rates.promprometheus.exporter.unixseries_detail--cost-per-1000-seriesestimated_cost*_count*_bucket*_sumgrafana_*/aggregations/rules./dpm-finder.py -e -p 9966 -u 86400http://localhost:PORT/metricsREADME.mddocker build -t dpm-finder:latest .
docker run --rm --env-file .env -v $(pwd)/output:/app/output \
dpm-finder:latest --format json --min-dpm 2.0README.mdmetrics:readPROMETHEUS_USERNAME--timeout--min-dpmPROMETHEUS_ENDPOINT.netdpm-finder.py # Main CLI tool (one-shot + exporter modes)
requirements.txt # Python dependencies
.env_example # Template for credential configuration
Dockerfile # Multi-stage Docker build
docker-compose.yml # Docker Compose orchestration
README.md # Full project documentation