justwatchcom / sql_exporter

Flexible SQL Exporter for Prometheus.
MIT License
404 stars 109 forks source link

exporter has a lot of default metrics #69

Closed weiya1990 closed 2 years ago

weiya1990 commented 2 years ago

for example:go_gc_pauses_seconds_total_bucket go_sched_latencies_seconds_bucket image image

marevers commented 2 years ago

Those are default Go metrics I believe. If there are any time series you don't want to ingest/scrape, use a metric relabel with drop action. Check here: https://prometheus.io/docs/prometheus/latest/configuration/configuration/#relabel_config

Or a specific example. The metric name is regex so you can also fuzzy match them.

scrape_configs:
 - job_name: 'my_job'
   static_configs:
     - targets:
       - my_target:1234
   metric_relabel_configs:
   - source_labels: [ __name__ ]
     regex: 'my_too_large_metric'
     action: drop