我在應用洞察創立了一套可用性測試工作,並希望添加警報通知團隊意想不到的失敗,但我沒有管理去做吧。警報在創建後不會改變它的狀態,它看起來像,它們根本無法獲取Metric數據。警報不應用洞察可用性指標
當我打開可用性測試資源(從應用洞察刀片或資源組) - 我看到一個巨大的圖表有很多關於它綠/紅點,顯示在過去的72年1月24日小時執行的測試:
當我嘗試創建一個公制警報,我選擇相同的可用性測試資源和正常運行時間度量,但提出的圖形顯示任何內容(注意嚴格水平線和第一千九百七十一年),而任何教程顯示nice graphs的示例
創建的任何警報不會對變化後的資源可用性的反應了。
這裏是我的ARM模板的一部分:
{
"apiVersion": "2016-03-01",
"name": "[variables('alerts').vehiclesHealth]",
"type": "microsoft.insights/alertrules",
"location": "[resourceGroup().location]",
"tags": {
"[concat('hidden-link:', resourceId('Microsoft.Insights/components', variables('appInsights').name))]": "Resource",
"displayName": "app-insights-alert",
"env": "[parameters('environment')]"
},
"properties": {
"name": "[variables('alerts').vehiclesHealth]",
"condition": {
"odata.type": "Microsoft.Azure.Management.Insights.Models.ThresholdRuleCondition",
"dataSource": {
"odata.type": "Microsoft.Azure.Management.Insights.Models.RuleMetricDataSource",
"resourceUri": "[resourceId('microsoft.insights/webtests', variables('tests').vehiclesHealth)]",
"metricName": "locations/emea-nl-ams-azr/metrics/GSMT_AvRaw"
},
"operator": "LessThan",
"threshold": 50,
"windowSize": "PT1H"
},
"actions": "[variables('alerts').actions]"
},
"dependsOn": [
"[resourceId('microsoft.insights/webtests', variables('tests').vehiclesHealth)]"
]
},
我想,我可能會用一個錯誤的度量標準名稱或資源引用,但我不知道如何去檢查一下。是否有任何Powershell腳本或REST API來獲取特定資源的所有可用指標?
我的主要問題是:我做錯了什麼,以及如何讓它工作?
團隊正在調查此... – ZakiMa