[CONFIGURATION] Add a resource detector extension example - #4423
Merged
dbarker merged 5 commits intoAug 13, 2026
Merged
Conversation
Signed-off-by: Mateen Anjum <mateenali66@gmail.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #4423 +/- ##
==========================================
- Coverage 82.59% 82.58% -0.00%
==========================================
Files 511 511
Lines 20039 20039
==========================================
- Hits 16550 16548 -2
- Misses 3489 3491 +2 🚀 New features to boost your workflow:
|
Signed-off-by: Mateen Anjum <mateenali66@gmail.com>
3 tasks
dbarker
approved these changes
Aug 13, 2026
dbarker
left a comment
Member
There was a problem hiding this comment.
Looks good. Thank you! Please see non blocking feedback below.
| opentelemetry::sdk::resource::Resource CustomResourceDetector::Detect() noexcept | ||
| { | ||
| OTEL_INTERNAL_LOG_ERROR("CustomResourceDetector::Detect(): YOUR CODE HERE"); | ||
| return ResourceDetector::Create({}); |
Member
There was a problem hiding this comment.
Consider adding the parsed comment as an attribute value :)
Member
Author
There was a problem hiding this comment.
done in the latest commit, Detect() now returns the parsed comment as custom.comment.
… example Signed-off-by: Mateen Anjum <mateenali66@gmail.com>
Signed-off-by: Mateen Anjum <mateenali66@gmail.com>
1 task
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Fixes #4419
Changes
Adds
CustomResourceDetectorandCustomResourceDetectorBuildertoexamples/configuration, mirroring the other Custom* extension skeletons (comment property read from yaml, YOUR CODE HERE placeholder inDetect()). The builder registers undermy_custom_detectorviaRegistry::SetExtensionResourceDetectorBuilder, matching the entry that already exists inextensions.yaml, whose placeholder comment now points at the implementation.As noted on the issue, the configured SDK will not build the detector until #4411 lands; this only provides the extension point wiring.
For significant contributions please make sure you have completed the following items:
CHANGELOG.mdupdated for non-trivial changes