Skip to content
This repository has been archived by the owner on Aug 14, 2024. It is now read-only.

Commit

Permalink
Metric Normalization note on w (#1219)
Browse files Browse the repository at this point in the history
  • Loading branch information
philipphofmann authored Apr 10, 2024
1 parent 1a841fd commit 83a7752
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/docs/sdk/metrics.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -63,11 +63,13 @@ class Aggregator:

Normalization shall be done for `statsd` envelope items with unicode support if possible.

* **Namespaces and Units:** regex `[^\w]+` with no replacement character.
* **Metric Keys/Names:** regex `[^\w\-.]+` with replacement character `_`.
* **Tag Keys:** regex `[^\w\-.\/]+` with no replacement character.
* **Namespaces and Units:** regex `[^a-zA-Z0-9_]+` with no replacement character.
* **Metric Keys/Names:** regex `[^a-zA-Z0-9_\-.]+` with replacement character `_`.
* **Tag Keys:** regex `[^a-zA-Z0-9_\-.\/]+` with no replacement character.
* **Tag Values:** See below

{/* Internal note: We can't use `\w` instead of `a-zA-Z0-9` because on some Regex engines `\w` includes chars such as `ä`, `ö` or `é`. */}

### Tag Values Replacement Map

Tag Values support the full UTF-8 character range, except for control characters.
Expand Down

0 comments on commit 83a7752

Please sign in to comment.