Closed Ankit-MSFT closed 8 months ago
Thank you for your feedback. Tagging and routing to the team member best able to assist.
Hi @Ankit-MSFT, we will look into why the error is not propagated and update the documentation. Thank you for your feedback!
[Enter feedback here]
Hello, we tried to use Azure.Monitor.Query package to retrieve metrics data for our resources. We were seeing empty results in MetricResult.TimeSeries in the response, when using below code. No error.
After troubleshooting multiple times, capturing requests through Fiddler and comparing it with REST API we figured out the values we were passing in the code were not correct.
Correct usage:
We had referred to multiple documentation: Documentation reference for the package List of supported metrics & resource providers Monitoring Storage account
Only after we used Metrics List API and compared it to the request Azure.Monitor.Query package was sending (captured details through fiddler), we were able to understand we were passing the wrong the values.
Queries:
Using 'BlobCount' as metric with 'Blob' as namespace should have thrown error. But we did not see any error instead we could see success response with empty result.
Can we update the documentation of Azure.Monitor.Query package MetricsQueryClient to include some more examples so that we understand what values to use in the options.
Thanks.
Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.