Azure / azure-sdk-for-go

This repository is for active development of the Azure SDK for Go. For consumers of the SDK we recommend visiting our public developer docs at:
https://docs.microsoft.com/azure/developer/go/
MIT License
1.64k stars 844 forks source link

armmonitoring MetricsClient.ListAtSubscriptionScopePost report unexpected error. #21796

Open yummydsky opened 1 year ago

yummydsky commented 1 year ago

Bug Report

Alancere commented 1 year ago

Hi @yummydsky, see your error message. There is no Network In Total and Network Out Total in the Valid metrics. Please try Network In and Network Out.

yummydsky commented 1 year ago

Hi @yummydsky, see your error message. There is no Network In Total and Network Out Total in the Valid metrics. Please try Network In and Network Out.

This is the real request and response from API metricsClient.List

{
  "cost": 8,
  "interval": "PT5M",
  "namespace": "Microsoft.Compute/virtualMachines",
  "resourceregion": "westus2",
  "timespan": "2023-10-18T05:49:34Z/2023-10-18T05:54:34Z",
  "value": [
    {
      "displayDescription": "The number of bytes received on all network interfaces by the Virtual Machine(s) (Incoming Traffic)",
      "errorCode": "Success",
      "id": "/subscriptions/xxx-xxx-xxx-xxx/resourceGroups/test-grp/providers/Microsoft.Compute/virtualMachines/test-vm-1/providers/Microsoft.Insights/metrics/Network In Total",
      "name": {
        "localizedValue": "Network In Total",
        "value": "Network In Total"
      },
      "timeseries": [
        {
          "data": [
            {
              "average": 45728.4,
              "timeStamp": "2023-10-18T05:49:00Z"
            }
          ],
          "metadatavalues": []
        }
      ],
      "type": "Microsoft.Insights/metrics",
      "unit": "Bytes"
    },
    {
      "displayDescription": "The number of bytes out on all network interfaces by the Virtual Machine(s) (Outgoing Traffic)",
      "errorCode": "Success",
      "id": "/subscriptions/xxx-xxx-xxx-xxx/resourceGroups/test-grp/providers/Microsoft.Compute/virtualMachines/test-vm-1/providers/Microsoft.Insights/metrics/Network Out Total",
      "name": {
        "localizedValue": "Network Out Total",
        "value": "Network Out Total"
      },
      "timeseries": [
        {
          "data": [
            {
              "average": 71674.6,
              "timeStamp": "2023-10-18T05:49:00Z"
            }
          ],
          "metadatavalues": []
        }
      ],
      "type": "Microsoft.Insights/metrics",
      "unit": "Bytes"
    }
  ]
}
github-actions[bot] commented 1 year ago

Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @SameergMS @dadunl @AzMonEssential @AzmonAlerts @AzmonActionG @AzmonLogA.