-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dropping lables configured in scraping config drops more metrics than requested #36061
Comments
Pinging code owners:
See Adding Labels via Comments if you do not have permissions to add labels yourself. |
Those timeseries aren't dropped--they are just combined into an OpenTelemetry histogram. The actual name of your metrics are Prometheus represents a histogram metric using multiple timeseries, with Prometheus relabel rules work on the timeseries, which means your initial configuration was correct. The
The |
Pinging code owners for exporter/prometheusremotewrite: @Aneurysm9 @rapphil @dashpole. See Adding Labels via Comments if you do not have permissions to add labels yourself. |
Thank you, @dashpole, for your answer. I did a few tests with my colleagues, and I think we understand how OTEL is different in this in comparison to "pure" Prometheus. Thank you for your explanation. |
Component(s)
receiver/prometheus
What happened?
Description
The scraping is configured like this:
This scraping should return the following metrics:
These metrics are then visible in Prometheus:
Debug output from the collector log.
If I add a drop action to the scraping for kubelet_pleg_relist_interval_seconds_count and kubelet_pleg_relist_interval_seconds_sum:
Then all the kubelet_pleg_relist_interval_seconds_.+ metrics are removed and not visible in Prometheus/Grafana.
Debug output from the collector log.
Steps to Reproduce
Use the config above for opentelemetry-contrib metrics collection.
Expected Result
To drop just the requested metrics.
Actual Result
Instead of dropping just kubelet_pleg_relist_interval_seconds_count and kubelet_pleg_relist_interval_seconds_sum metric also kubelet_pleg_relist_interval_seconds_bucket is dropped.
Collector version
0.112.0-amd64
Environment information
Environment
K8S 1.29
K8S 1.30
OpenTelemetry Collector configuration
Log output
Logs are mentioned in the description part of this issue.
Additional context
If we call the scraping with Prometheus agent, it works as expected.
The text was updated successfully, but these errors were encountered: