-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Metrics transform processor: replace version in label values #876
Metrics transform processor: replace version in label values #876
Conversation
Codecov Report
@@ Coverage Diff @@
## master #876 +/- ##
==========================================
- Coverage 88.30% 88.28% -0.03%
==========================================
Files 234 234
Lines 12464 12466 +2
==========================================
- Hits 11006 11005 -1
- Misses 1108 1111 +3
Partials 350 350
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
1a014a0
to
23a0ed8
Compare
operations: | ||
- action: add_label | ||
new_label: version | ||
new_value: opentelemetry collector {{version}} |
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: Ideally there should be a way to escape this and be able to pass the {{version}}
string as is (without replacement).
Though in practice I doubt anyone would ever run into this limitation.
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.
I guess it's possible that some other processor also does substitution for {{version}}
, but in a different way / with a different value. In that case the ordering of processors will matter.
Still don't think this is a real issue though.
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.
Yea this is a very simple substitution so I only defined trivial semantics.
Note the substitution only applies the configured values themselves, not the metric label values (so I don't think your second comment is relevant).
I may come back and add something more sophisticated later - I agree there should eventually be a way to escape this.
23a0ed8
to
36c1856
Compare
* Prepare for releasing v0.7.0 * Update Changelog for v0.7.0 release Co-authored-by: Joshua MacDonald <jmacd@users.noreply.github.com>
Replace
{{version}}
in any label values in the metrics transform processor with the app version.