Sanitize dimensions to avoid scraping from breaking. Resolves #65 and #38
Checklist
[x] The provided tests still run.
[x] I've created new tests where needed.
[x] I've updated the documentation if necessary.
Motivation and Context
If dimensions aren't sanitized then Prometheus breaks with errors like
error while linting: text format parsing error in line 9: expected '=' after label name, found '-'
Description
Run dimensions through a sanitizer. Uses a new DimensionsSanitizer as uppercase ASCII is allowed. (It looks like regular labels should allow uppercase as well but I didn't want to change that).
Also split out sanitiser types into their own files
Sanitize dimensions to avoid scraping from breaking. Resolves #65 and #38
Checklist
Motivation and Context
If dimensions aren't sanitized then Prometheus breaks with errors like
Description
Run dimensions through a sanitizer. Uses a new
DimensionsSanitizer
as uppercase ASCII is allowed. (It looks like regular labels should allow uppercase as well but I didn't want to change that).Also split out sanitiser types into their own files