-
Notifications
You must be signed in to change notification settings - Fork 2.6k
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
[metricstransform] Add resource attribute copy to metric label #2630
Conversation
I can't figure out how to reference the |
9177f37
to
6ae6d63
Compare
Codecov Report
@@ Coverage Diff @@
## main #2630 +/- ##
=======================================
Coverage 91.47% 91.47%
=======================================
Files 439 440 +1
Lines 21855 21870 +15
=======================================
+ Hits 19991 20005 +14
- Misses 1394 1395 +1
Partials 470 470
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
9abaa9b
to
14e30b1
Compare
This PR works in my tests, is documented, and has tests. |
This should be done by enabling
|
…open-telemetry#2630) Signed-off-by: Bogdan Drutu <[email protected]>
The |
This PR was marked stale due to lack of activity. It will be closed in 7 days. |
The |
What should one do if further data processing is required? This being at the exporter stage doesn't allow that. Perhaps we could revisit this and think of adding similar feature at the processor stage? WDYT @mxiamxia ? |
I still see value in this functionality. I can certainly see how adding this functionality can be confusing when Let me see if I can describe my use case. I'm scraping metrics from services using the One option I considered was to instead use the It seems a common pattern to do joins against an information metric to help expand context when necessary while also reducing cardinality/active series. Typically you would do this with some unique The problem is I would now need to build logic into each service to have a Perhaps there are better approaches for what I'm looking to achieve, so open to other options. |
I'd love to see this feature as well. resource_to_telemetry_conversion doesn't meet our needs if we do not need that extra metrics label. |
@awiddersheim and @singku the transformprocessor may be able to meet your needs. It is able to set the attribute of data points using a resource attribute. It looks like |
Thank you Tyler, I will give it a try |
Description:
Add the ability to copy resource attributes into metric labels. This allows users to use resource attributes like "hostname" or "pod name" as labels in metrics without having to re-instrument the application.
This is a WIP as I can't get the tests to pass yet and I would like some feedback before spending any more time on it.
Link to tracking Issue:
#2568
Testing:
I added a test case for the new operation
Documentation: