Let groundcover automatically scrape your custom metrics
groundcover can scrape your custom metrics by deploying a metrics scraper (vmagent by Victoria Metrics) that will automatically scrape prometheus targets.
vmagent is fully compatible with prometheus scrape job syntax - more can be found here.
Enabling custom metrics scraping
The following helm override enables custom metrics scraping
custom-metrics:enabled:true
Using CLI
Scrape your custom metrics using groundcover CLI (using default scrape jobs):
groundcoverdeploy--custom-metrics
Using Helm
Using Helm (Upgrading existing installation)
Either create a new custom-values.yaml or edit your existing groundcover values.yaml
Ensure that the Kubernetes resources that contain your Prometheus exporters have been deployed with the following annotations to enable scraping
By default, the following scrape jobs are deployed when enabling custom-metrics:
Starting November 25th 2024, kubernetes-pods scraping job will be the only scrape job that is enabled out of the box when activating custom metrics scraping.
You can add back the legacy scrape jobs under extraScrapeConfigs section as described in Using custom scrape jobs
Disable autodiscovery scrape jobs
In case you're interested in disabling autodiscovery scrape jobs, provide the below override
Disabling custom-metrics scrape jobs allows you to scale the custom-metrics deployment horizontally.
Using custom scrape jobs
in case you're interested in deploying custom scrape jobs, create/add the following override
Cardinality limits
In order to safeguard groundcover's performance, there are default limitations on metrics ingestion in place.
Increasing metrics cardinality
In order to increase metrics resolution, you can implement the following overrides
Increasing cardinality parameters will increase memory/cpu consumption and might cause OOMKills/CPU Throttling.
Please use with caution and increase the custom metrics agent/metrics server resources accordingly
In case you wish to increase metrics server / custom metrics resources, use the following overrides: