Skip to content

Cannot set header x-honeycomb-dataset using the service.name resource attribute #36538

@NeilLobo-kubra

Description

@NeilLobo-kubra

Component(s)

No response

Describe the issue you're reporting

I am using honeycomb classic and OTEL v0.88 and I have been trying to set the dataset header using resource attribute service.name but its not working for me.

If I cant upgrade from honeycomb classic how would I in essence use the data in the processor to set the header in the exporter.

This is the code I have now:

exporters:
    otlp/k8s-metrics:
      headers:
        "x-honeycomb-team": "${env:HONEYCOMB_API_KEY}"
        "x-honeycomb-dataset": "${service.name}-metrics"

and

exporters:
    otlp/k8s-metrics:
      headers:
        "x-honeycomb-team": "${env:HONEYCOMB_API_KEY}"
        "x-honeycomb-dataset": "resource.attributes["service.name"]-metrics"

the second excerpt returns dataset as resource.attributes["service.name"]-metrics and the first one returns -metrics and therefore I cannot dynamically set the header.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions