-
Notifications
You must be signed in to change notification settings - Fork 8
Wrap OTel Resource message with top-level ProcessContext message #53
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
Merged
felixge
merged 4 commits into
open-telemetry:main
from
ivoanjo:ivoanjo/replace-process-context-payload
Feb 18, 2026
Merged
Changes from all commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
79e62c7
Wrap OTel Resource message with top-level ProcessContext message
ivoanjo 94d5b78
Update README for reference implementation
ivoanjo ff3dded
Update namespace after discussion in profiling SIG
ivoanjo 825b988
Merge branch 'main' into ivoanjo/replace-process-context-payload
christos68k File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,55 @@ | ||
| // Copyright 2019, OpenTelemetry Authors | ||
| // | ||
| // Licensed under the Apache License, Version 2.0 (the "License"); | ||
| // you may not use this file except in compliance with the License. | ||
| // You may obtain a copy of the License at | ||
| // | ||
| // http://www.apache.org/licenses/LICENSE-2.0 | ||
| // | ||
| // Unless required by applicable law or agreed to in writing, software | ||
| // distributed under the License is distributed on an "AS IS" BASIS, | ||
| // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
| // See the License for the specific language governing permissions and | ||
| // limitations under the License. | ||
|
|
||
| syntax = "proto3"; | ||
|
|
||
| // TODO: Is this in the right namespace? Since this is not only for profiling, | ||
| // `opentelemetry.proto.profiles` doesn't seem the right place, but perhaps common ain't | ||
| // it either? Feedback very welcome! | ||
| package opentelemetry.proto.common.v1; | ||
|
|
||
| import "common.proto"; | ||
| import "resource.proto"; | ||
|
|
||
| option csharp_namespace = "OpenTelemetry.Proto.Common.V1"; | ||
| option java_multiple_files = true; | ||
| option java_package = "io.opentelemetry.proto.common.v1"; | ||
| option java_outer_classname = "ProcessContextProto"; | ||
| option go_package = "go.opentelemetry.io/proto/otlp/common/v1"; | ||
|
|
||
| // ProcessContext represents the payload for the process context sharing mechanism. | ||
| // | ||
| // This message is designed to be published by OpenTelemetry SDKs via a memory-mapped | ||
| // region, allowing external readers (such as the OpenTelemetry eBPF Profiler) to | ||
| // discover and read resource attributes from instrumented processes without requiring | ||
| // direct integration or process activity. | ||
| message ProcessContext { | ||
| // The resource attributes describing this process. | ||
| // | ||
| // Attribute keys MUST be unique (it is not allowed to have more than one | ||
| // attribute with the same key). The behavior of software that receives | ||
| // duplicated keys can be unpredictable. | ||
| // | ||
| // Attributes SHOULD follow OpenTelemetry semantic conventions where applicable. | ||
| // See: https://opentelemetry.io/docs/specs/semconv/ | ||
| opentelemetry.proto.resource.v1.Resource resource = 1; | ||
|
|
||
| // Additional attributes to share with external readers that are not part of | ||
| // the standard Resource. [Optional] | ||
| // | ||
| // This field allows publishers to include supplementary key-value pairs that | ||
| // may be useful for external readers but are not part of the SDK's configured | ||
| // Resource. | ||
| repeated opentelemetry.proto.common.v1.KeyValue extra_attributes = 2; | ||
| } |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: Maybe if you do additional modifications in the future to address OTEP comments, add 1-2 attributes in extra_attributes to demonstrate non-resource attribute handling.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeap, sounds good! I need to make a few tweaks to support the thread context which is an extra_attribute so I'll include that as well.