Microsoft.Extensions.Diagnostics.ResourceMonitoring meter name changed to ResourceMonitoring #5404
Labels
area-telemetry
bug
This issue describes a behavior which is not expected - a bug.
work in progress 🚧
Description
The following commit cbcef5c changed the name of Microsoft.Extensions.Diagnostics.ResourceMonitoring main meter.
The correct one is Microsoft.Extensions.Diagnostics.ResourceMonitoring. The current value (for v8.8) is "ResourceMonitoring".
The problem is with nameof expression
meterFactory.Create(nameof(Microsoft.Extensions.Diagnostics.ResourceMonitoring));
Please check https://learn.microsoft.com/en-us/dotnet/csharp/language-reference/operators/nameof When the operand is a type or a namespace, the produced name isn't fully qualified
I provide a PR that fixes this bug #5403
Reproduction Steps
AddMeeter("Microsoft.Extensions.Diagnostics.ResourceMonitoring")
Run any sample program. ResourceMonitoring Metrics are no longer produced.
Expected behavior
AddMeeter("Microsoft.Extensions.Diagnostics.ResourceMonitoring")
gives ResourceMonitoring metrics.Actual behavior
AddMeeter("Microsoft.Extensions.Diagnostics.ResourceMonitoring")
gives no ResourceMonitoring metrics.Regression?
Worked in < v8.8
Known Workarounds
No response
Configuration
No response
Other information
No response
The text was updated successfully, but these errors were encountered: