Skip to content
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

[processor / spanmetricsprocessor] dropping the condition to replace _ with key_ as __ is reserved and _ is not #8057

Merged

Conversation

saikrishna397
Copy link
Contributor

@saikrishna397 saikrishna397 commented Feb 22, 2022

Description: when sanitizeLabel feature flag is enabled, labels that start with _ are not updated. labels that start with __ are sanitized irrespective of this flag since __ is reserved in prometheus and _ is not.

followed the same approach as #7112 & #7506

Link to tracking Issue:

Testing: emit a metric that has a label starting with _ and it should not be prefixed with key when skipSanitizeLabel is enabled.

Documentation:

@saikrishna397 saikrishna397 requested review from a team and mx-psi February 22, 2022 00:17
@mx-psi
Copy link
Member

mx-psi commented Feb 22, 2022

@codeboten @Aneurysm9, since you reviewed the other related PRs, could you have a look at this one?

Copy link
Member

@mx-psi mx-psi left a comment

Choose a reason for hiding this comment

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

I will defer to @codeboten and @Aneurysm9 opinions, but I think adding Prometheus-specific logic to a component that is, in principle, independent of Prometheus, is an anti-pattern that should be avoided

CHANGELOG.md Outdated Show resolved Hide resolved
processor/spanmetricsprocessor/config.go Outdated Show resolved Hide resolved
@saikrishna397
Copy link
Contributor Author

@Aneurysm9 , @mx-psi could you please review and let me know if there're any changes pending.

@jpkrohling jpkrohling merged commit 32430b4 into open-telemetry:main Mar 8, 2022
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.

5 participants