Skip to content

Conversation

@gregkalapos
Copy link
Contributor

deployment.environment.name was introduced in SemConv v1.27.0 and deployment.environment got deprecated.

In the otel-data ES plugin we alias service.environment to deployment.environment. service.environment is used by Kibana to show the environment.

In this PR, if deployment.environment.name is set, we duplicate it into deployment.environment in order to make the service.environment -> deployment.environment work.

So far there is no better solution on the table - ideally we'd need an ES feature where the service.environment alias has two targets, but currently that is not possible in ES.

@gregkalapos gregkalapos self-assigned this Mar 21, 2025
@gregkalapos gregkalapos marked this pull request as ready for review March 21, 2025 13:32
@gregkalapos gregkalapos requested a review from a team as a code owner March 21, 2025 13:32
If `deployment.environment.name` is set, we duplicate it into `deployment.environment` in order to make the `service.environment` -> `deployment.environment` work.
@gregkalapos gregkalapos force-pushed the handle_deployment_environment_name branch from db5633c to 2072617 Compare March 21, 2025 17:18
Copy link
Contributor

@lahsivjar lahsivjar left a comment

Choose a reason for hiding this comment

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

Just a minor nit.

Co-authored-by: Vishal Raj <vishal.raj@elastic.co>
@gregkalapos gregkalapos merged commit 0f63cf5 into elastic:main Mar 24, 2025
3 checks passed
@gregkalapos gregkalapos deleted the handle_deployment_environment_name branch March 24, 2025 09:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants