Skip to content
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

Unable to add custom attributes under service #11727

Open
fabry00 opened this issue Nov 21, 2024 · 0 comments
Open

Unable to add custom attributes under service #11727

fabry00 opened this issue Nov 21, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@fabry00
Copy link

fabry00 commented Nov 21, 2024

Describe the bug
I'd like to add several attributes under service.* but so far all the attributes that I've added in the processors.resource.atrtibutes are added as children of labels.*

Steps to reproduce

Given the following configuration:

receivers:
  otlp:
    protocols:
      grpc:
        endpoint: 0.0.0.0:4317
      http:
        endpoint: 0.0.0.0:4318

processors:
  memory_limiter:
    check_interval: 1s
    limit_mib: 2000
  resource:
    attributes:
    - key: deployment.environment
      action: insert
      value: dev
    - key: service.cluster
      value: XXXX
      action: insert
    - key: cluster
      value: XXXX
      action: insert

exporters:
  debug:
    verbosity: detailed

....
....

The attribute service.cluster will be injected as labels.service_cluster while cluster in labels.cluster

What did you expect to see?
service.cluster: XXXX

What did you see instead?
labels.service_cluster:XXXX or
labels.cluster: XXXX

What version did you use?
0.108.0

Environment
openshift

Additional context

ScopeSpans SchemaURL: 
...
Span #0
    Trace ID       : 2760dc4ca9976b747cc7752ee79f36b9
    Parent ID      : 
    .....
    Status message : 
Attributes:
     -> http.scheme: Str(https)
     -> http.client_ip: Str(172.16.8.1)
     -> kong.request.id: Str(f71b580eba670e4c66d6902551bcdd61)
     -> http.method: Str(GET)
     .....   
ResourceSpans #1
Resource SchemaURL: 
Resource attributes:
     -> service.name:xxxxx
     -> service.version: xxxxx
     -> service.instance.id: xxxxx
     -> deployment.environment: Str(dev)
     -> service.cluster: xxxx
     -> customer: xxxxx
@fabry00 fabry00 added the bug Something isn't working label Nov 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant