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

Special characters used in the dogstatsd protocol are not escaped in metric name and namespace #740

Open
deadok22 opened this issue Oct 25, 2022 · 1 comment
Labels
kind/bug Bug related issue stale Stale - Bot reminder

Comments

@deadok22
Copy link

The metric serialization logic replaces special characters used in the dogstatsd protocol in tags, but not in metric namespace and name.

There are similar issues in other dogstatsd client libraries:

@deadok22 deadok22 added the kind/bug Bug related issue label Oct 25, 2022
@github-actions
Copy link

Thanks for your contribution!

This issue has been automatically marked as stale because it has not had activity in the last 30 days. Note that the issue will not be automatically closed, but this notification will remind us to investigate why there's been inactivity. Thank you for participating in the Datadog open source community.

If you would like this issue to remain open:

  1. Verify that you can still reproduce the issue in the latest version of this project.

  2. Comment that the issue is still reproducible and include updated details requested in the issue template.

@github-actions github-actions bot added the stale Stale - Bot reminder label Nov 24, 2022
walerian777 pushed a commit to walerian777/datadogpy that referenced this issue Dec 12, 2022
According to the documentation
https://docs.datadoghq.com/metrics/custom_metrics/#naming-custom-metrics
metric names contain only ASCII alphanumerics, underscores,
and periods, while other characters are converted to underscores.

This commit ensures we replace all invalid characters with underscores
for both namespaces and metric names.

A similar thing has been already done for tags in DataDog#489 and DataDog#517,
so I followed the example.

It solves DataDog#740.
walerian777 pushed a commit to walerian777/datadogpy that referenced this issue Dec 12, 2022
According to the documentation
https://docs.datadoghq.com/metrics/custom_metrics/#naming-custom-metrics
metric names contain only ASCII alphanumerics, underscores,
and periods, while other characters are converted to underscores.

This commit ensures we replace all invalid characters with underscores
for both namespaces and metric names.

A similar thing has been already done for tags in DataDog#489 and DataDog#517,
so I followed the example.

It solves DataDog#740.
walerian777 pushed a commit to walerian777/datadogpy that referenced this issue Dec 12, 2022
According to the documentation
https://docs.datadoghq.com/metrics/custom_metrics/#naming-custom-metrics
metric names contain only ASCII alphanumerics, underscores,
and periods, while other characters are converted to underscores.

This commit ensures we replace all invalid characters with underscores
for both namespaces and metric names.

A similar thing has been already done for tags in DataDog#489 and DataDog#517,
so I followed the example.

It solves DataDog#740.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Bug related issue stale Stale - Bot reminder
Projects
None yet
Development

No branches or pull requests

1 participant