[bug] Throw an exception when an unsupported counter name is created #5990
Labels
bug
Something isn't working
needs-runtime-change
Issues which likely require changes from dotnet runtime - typically DiagnosticSource package
pkg:OpenTelemetry
Issues related to OpenTelemetry NuGet package
Package
OpenTelemetry
Package Version
Runtime Version
4.8
Description
When a counter is created with a space within it, There are no errors thrown but the metrics just doesnt get published / exported.
Steps to Reproduce
SomeMeter.CreateCounter("Code Generated");
Expected Result
Throws an exception when the counter is created suggesting the name is not supported.
Actual Result
Doesn't throw an error but also does not post the metrics
Additional Context
No response
The text was updated successfully, but these errors were encountered: