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

Fix OpenTelemetry service name #9619

Merged
merged 5 commits into from
Jan 6, 2023

Conversation

tomMoulard
Copy link
Member

@tomMoulard tomMoulard commented Dec 26, 2022

What does this PR do?

This PR adds the service.name and service.version resource attribute to the otel exporter to Traefik's OpenTelemetry metrics and trace exporter.

It goes from:

Resource attributes:
      -> service.name: Str(unknown_service:traefik)
      -> telemetry.sdk.language: Str(go)
      -> telemetry.sdk.name: Str(opentelemetry)
      -> telemetry.sdk.version: Str(1.11.2)

To:

Resource attributes:
     -> service.name: Str(traefik) # <-- updated
     -> service.version: Str(dev) # <-- added
     -> telemetry.sdk.language: Str(go)
     -> telemetry.sdk.name: Str(opentelemetry)
     -> telemetry.sdk.version: Str(1.11.2)

This PR also fixes a small typo in the doc.

Motivation

Have a correct service.name resource for the OpenTelemetry metrics/trace exporter.

Fix #9617.

More

  • Added/updated tests
  • Added/updated documentation (but not for this)

Additional comments

Co-authored-by: Kevin Pollet pollet.kevin@gmail.com

Copy link
Member

@rtribotte rtribotte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👌

@kevinpollet kevinpollet changed the title Fix otel service name Fix OpenTelemetry service name Jan 3, 2023
Copy link
Member

@kevinpollet kevinpollet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

OpenTelemetry Tracing - resource attribute service.name = unknown_service:traefik
5 participants