Skip to content

[receiver/prometheusreceiver] does not handle native histograms with custom bucket correctly #41131

@krajorama

Description

@krajorama

Component(s)

receiver/prometheus

What happened?

Description

Native histograms with custom buckets should be converted to explicit Otel histograms, not exponential Otel histograms with fake schema -53.

See https://prometheus.io/docs/specs/native_histograms/#custom-values

Steps to Reproduce

Add unit test to enable Prometheus parsing to produce NHCB.
Enable the native histograms feature gate.
No need for protobuf input, normal text will work.

Expected Result

Explicit histogram metric on Otel side.

Actual Result

I expect invalid exponential histogram.

Collector version

v0.128.0

Environment information

Environment

OS: (e.g., "Ubuntu 20.04")
Compiler(if manually compiled): (e.g., "go 14.2")

OpenTelemetry Collector configuration

Log output

Additional context

No response

Tip

React with 👍 to help prioritize this issue. Please use comments to provide useful context, avoiding +1 or me too, to help us triage it. Learn more here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingnever staleIssues marked with this label will be never staled and automatically removedreceiver/prometheusPrometheus receiver

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions