Closed ctrader2 closed 9 months ago
Pinging code owners:
See Adding Labels via Comments if you do not have permissions to add labels yourself.
I would suggest giving the following configuration a try.
exporters:
otlp:
endpoint: grafana-agent:4317
tls:
insecure: true
prometheus:
endpoint: "0.0.0.0:8889"
enable_open_metrics: true
add_metric_suffixes: false
resource_to_telemetry_conversion: true // If `enabled` is `true`, all the resource attributes will be converted to metric labels by default.
@ctrader2 have you been able to test @yantingqiu's shared configuration?
Note: I believe the correct configuration for this option would be:
resource_to_telemetry_conversion:
enabled: true
I'm going to close for now as I believe the suggested configuration update will resolve the issue. Please let us know though if you get a chance to test and that's not the case!
Component(s)
connector/spanmetrics, exporter/prometheus
What happened?
Description
I am using the
spanmetricsconnector
in conjunction withprometheusexporter
. I want to attach exemplars to the Prometheus metrics being generated. Based on the documentation for each of these components, I configuredexemplars:enabled:true
for thespanmetricsconnector
andenable_open_metrics:true
for theprometheusexporter
.It looks like exemplars are attached correctly to the OTEL metrics generated by
spanmetricsconnector
but are not carried forward/attached after conversion to Prometheus format.Steps to Reproduce
spanmetricsconnector
Expected Result
Trace IDs attached to each Prometheus metric.
Actual Result
No trace information is attached.
Collector version
v0.88.0
Environment information
No response
OpenTelemetry Collector configuration
Log output
Additional context
No response