Scheduled Query Rules - Create Or Update

예약된 쿼리 규칙을 만들거나 업데이트합니다.

PUT https://management.azure.com/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Insights/scheduledQueryRules/{ruleName}?api-version=2021-08-01

URI 매개 변수

Name In(다음 안에) 필수 형식 Description
resourceGroupName
path True

string

리소스 그룹의 이름. 이름은 대소문자를 구분하지 않습니다.

ruleName
path True

string

규칙의 이름입니다.

subscriptionId
path True

string

대상 구독의 ID입니다.

api-version
query True

string

이 작업에 사용할 API 버전입니다.

요청 본문

Name 필수 형식 Description
location True

string

리소스가 있는 지리적 위치

properties.criteria True

ScheduledQueryRuleCriteria

예약된 쿼리 규칙의 조건을 정의하는 규칙 조건입니다.

properties.enabled True

boolean

이 예약된 쿼리 규칙을 사용할 수 있는지 여부를 나타내는 플래그입니다. 값은 true 또는 false여야 합니다.

properties.scopes True

string[]

이 예약된 쿼리 규칙의 범위가 지정된 리소스 ID 목록입니다.

kind

Kind

예약된 쿼리 규칙의 유형을 나타냅니다. 기본값은 LogAlert입니다.

properties.actions

Actions

경고가 발생할 때 호출하는 작업입니다.

properties.autoMitigate

boolean

경고를 자동으로 해결해야 하는지 여부를 나타내는 플래그입니다. 기본값은 true입니다. LogAlert 종류의 규칙에만 관련됩니다.

properties.checkWorkspaceAlertsStorageConfigured

boolean

이 예약된 쿼리 규칙을 고객의 스토리지에 저장해야 하는지 여부를 나타내는 플래그입니다. 기본값은 false입니다. LogAlert 종류의 규칙에만 관련됩니다.

properties.description

string

예약된 쿼리 규칙에 대한 설명입니다.

properties.displayName

string

경고 규칙의 표시 이름

properties.evaluationFrequency

string

예약된 쿼리 규칙이 ISO 8601 기간 형식으로 표시되는 빈도입니다. LogAlert 종류의 규칙에만 관련되고 필요합니다.

properties.muteActionsDuration

string

경고가 발생한 후 선택한 기간(ISO 8601 기간 형식)에 대한 작업을 음소거합니다. LogAlert 종류의 규칙에만 관련됩니다.

properties.overrideQueryTimeRange

string

지정된 경우 쿼리 시간 범위를 재정의합니다(기본값은 WindowSize*NumberOfEvaluationPeriods). LogAlert 종류의 규칙에만 관련됩니다.

properties.severity

AlertSeverity

경고의 심각도입니다. [0-4] 사이의 정수여야 합니다. 값 0이 가장 심각합니다. LogAlert 종류의 규칙에만 관련되고 필요합니다.

properties.skipQueryValidation

boolean

제공된 쿼리의 유효성을 검사해야 하는지 여부를 나타내는 플래그입니다. 기본값은 false입니다. LogAlert 종류의 규칙에만 관련됩니다.

properties.targetResourceTypes

string[]

경고가 생성/업데이트되는 대상 리소스의 리소스 종류 목록입니다. 예를 들어 scope 리소스 그룹이고 targetResourceTypes가 Microsoft.Compute/virtualMachines인 경우 경고 조건을 충족하는 리소스 그룹의 각 가상 머신에 대해 다른 경고가 발생합니다. LogAlert 종류의 규칙에만 관련

properties.windowSize

string

경고 쿼리가 실행될 기간(ISO 8601 기간 형식)(bin 크기)입니다. LogAlert 종류의 규칙에만 관련되고 필요합니다.

tags

object

리소스 태그.

응답

Name 형식 Description
200 OK

ScheduledQueryRuleResource

예약된 쿼리 규칙 업데이트 요청 성공

201 Created

ScheduledQueryRuleResource

예약된 쿼리 규칙 만들기

Other Status Codes

ErrorContract

작업이 실패한 이유를 설명하는 오류 응답입니다.

보안

azure_auth

Azure Active Directory OAuth2 Flow

Type: oauth2
Flow: implicit
Authorization URL: https://login.microsoftonline.com/common/oauth2/authorize

Scopes

Name Description
user_impersonation 사용자 계정 가장

예제

Create or update a scheduled query rule for Single Resource
Create or update a scheduled query rule on Resource group(s)
Create or update a scheduled query rule on Subscription

Create or update a scheduled query rule for Single Resource

Sample Request

PUT https://management.azure.com/subscriptions/dd4bfc94-a096-412b-9c43-4bd13e35afbc/resourceGroups/QueryResourceGroupName/providers/Microsoft.Insights/scheduledQueryRules/perf?api-version=2021-08-01

{
  "location": "eastus",
  "properties": {
    "description": "Performance rule",
    "severity": 4,
    "enabled": true,
    "evaluationFrequency": "PT5M",
    "scopes": [
      "/subscriptions/aaf177ed-1330-a9f2-80ea-fd3d7783b147/resourceGroups/scopeResourceGroup1/providers/Microsoft.Compute/virtualMachines/vm1"
    ],
    "windowSize": "PT10M",
    "criteria": {
      "allOf": [
        {
          "query": "Perf | where ObjectName == \"Processor\"",
          "timeAggregation": "Average",
          "metricMeasureColumn": "% Processor Time",
          "resourceIdColumn": "resourceId",
          "dimensions": [
            {
              "name": "ComputerIp",
              "operator": "Exclude",
              "values": [
                "192.168.1.1"
              ]
            },
            {
              "name": "OSType",
              "operator": "Include",
              "values": [
                "*"
              ]
            }
          ],
          "operator": "GreaterThan",
          "threshold": 70,
          "failingPeriods": {
            "numberOfEvaluationPeriods": 1,
            "minFailingPeriodsToAlert": 1
          }
        }
      ]
    },
    "muteActionsDuration": "PT30M",
    "actions": {
      "actionGroups": [
        "/subscriptions/1cf177ed-1330-4692-80ea-fd3d7783b147/resourcegroups/sqrapi/providers/microsoft.insights/actiongroups/myactiongroup"
      ],
      "customProperties": {
        "key11": "value11",
        "key12": "value12"
      }
    },
    "autoMitigate": true,
    "checkWorkspaceAlertsStorageConfigured": true,
    "skipQueryValidation": true
  }
}

Sample Response

{
  "id": "/subscriptions/dd4bfc94-a096-412b-9c43-4bd13e35afbc/resourcegroups/QueryResourceGroupName/providers/microsoft.insights/scheduledqueryrules/perf",
  "name": "perf",
  "type": "microsoft.insights/scheduledqueryrules",
  "location": "eastus",
  "tags": {},
  "properties": {
    "description": "Performance rule",
    "severity": 4,
    "enabled": true,
    "evaluationFrequency": "PT5M",
    "scopes": [
      "/subscriptions/aaf177ed-1330-a9f2-80ea-fd3d7783b147/resourceGroups/scopeResourceGroup1/providers/Microsoft.Compute/virtualMachines/vm1"
    ],
    "windowSize": "PT10M",
    "criteria": {
      "allOf": [
        {
          "query": "Perf | where ObjectName == \"Processor\"",
          "timeAggregation": "Average",
          "metricMeasureColumn": "% Processor Time",
          "resourceIdColumn": "resourceId",
          "dimensions": [
            {
              "name": "ComputerIp",
              "operator": "Exclude",
              "values": [
                "192.168.1.1"
              ]
            },
            {
              "name": "OSType",
              "operator": "Include",
              "values": [
                "*"
              ]
            }
          ],
          "operator": "GreaterThan",
          "threshold": 70,
          "failingPeriods": {
            "numberOfEvaluationPeriods": 1,
            "minFailingPeriodsToAlert": 1
          }
        }
      ]
    },
    "muteActionsDuration": "PT30M",
    "actions": {
      "actionGroups": [
        "/subscriptions/1cf177ed-1330-4692-80ea-fd3d7783b147/resourcegroups/sqrapi/providers/microsoft.insights/actiongroups/myactiongroup"
      ],
      "customProperties": {
        "key11": "value11",
        "key12": "value12"
      }
    },
    "autoMitigate": true,
    "isWorkspaceAlertsStorageConfigured": true,
    "checkWorkspaceAlertsStorageConfigured": true,
    "skipQueryValidation": true
  }
}
{
  "id": "/subscriptions/dd4bfc94-a096-412b-9c43-4bd13e35afbc/resourcegroups/QueryResourceGroupName/providers/microsoft.insights/scheduledqueryrules/perf",
  "name": "perf",
  "type": "microsoft.insights/scheduledqueryrules",
  "location": "eastus",
  "tags": {},
  "properties": {
    "description": "Performance rule",
    "severity": 4,
    "enabled": true,
    "evaluationFrequency": "PT5M",
    "scopes": [
      "/subscriptions/aaf177ed-1330-a9f2-80ea-fd3d7783b147/resourceGroups/scopeResourceGroup1/providers/Microsoft.Compute/virtualMachines/vm1"
    ],
    "windowSize": "PT10M",
    "criteria": {
      "allOf": [
        {
          "query": "Perf | where ObjectName == \"Processor\"",
          "timeAggregation": "Average",
          "metricMeasureColumn": "% Processor Time",
          "resourceIdColumn": "resourceId",
          "dimensions": [
            {
              "name": "ComputerIp",
              "operator": "Exclude",
              "values": [
                "192.168.1.1"
              ]
            },
            {
              "name": "OSType",
              "operator": "Include",
              "values": [
                "*"
              ]
            }
          ],
          "operator": "GreaterThan",
          "threshold": 70,
          "failingPeriods": {
            "numberOfEvaluationPeriods": 1,
            "minFailingPeriodsToAlert": 1
          }
        }
      ]
    },
    "muteActionsDuration": "PT30M",
    "actions": {
      "actionGroups": [
        "/subscriptions/1cf177ed-1330-4692-80ea-fd3d7783b147/resourcegroups/sqrapi/providers/microsoft.insights/actiongroups/myactiongroup"
      ],
      "customProperties": {
        "key11": "value11",
        "key12": "value12"
      }
    },
    "autoMitigate": true,
    "isWorkspaceAlertsStorageConfigured": true,
    "checkWorkspaceAlertsStorageConfigured": true,
    "skipQueryValidation": true
  }
}

Create or update a scheduled query rule on Resource group(s)

Sample Request

PUT https://management.azure.com/subscriptions/dd4bfc94-a096-412b-9c43-4bd13e35afbc/resourceGroups/QueryResourceGroupName/providers/Microsoft.Insights/scheduledQueryRules/heartbeat?api-version=2021-08-01

{
  "location": "eastus",
  "properties": {
    "description": "Health check rule",
    "severity": 4,
    "enabled": true,
    "evaluationFrequency": "PT5M",
    "scopes": [
      "/subscriptions/aaf177ed-1330-a9f2-80ea-fd3d7783b147/resourceGroups/scopeResourceGroup1"
    ],
    "targetResourceTypes": [
      "Microsoft.Compute/virtualMachines"
    ],
    "windowSize": "PT10M",
    "criteria": {
      "allOf": [
        {
          "query": "Heartbeat",
          "timeAggregation": "Count",
          "dimensions": [],
          "operator": "GreaterThan",
          "threshold": 360,
          "failingPeriods": {
            "numberOfEvaluationPeriods": 1,
            "minFailingPeriodsToAlert": 1
          }
        }
      ]
    },
    "muteActionsDuration": "PT30M",
    "actions": {
      "actionGroups": [
        "/subscriptions/1cf177ed-1330-4692-80ea-fd3d7783b147/resourcegroups/sqrapi/providers/microsoft.insights/actiongroups/myactiongroup"
      ],
      "customProperties": {
        "key11": "value11",
        "key12": "value12"
      }
    },
    "autoMitigate": true,
    "checkWorkspaceAlertsStorageConfigured": true,
    "skipQueryValidation": true
  }
}

Sample Response

{
  "id": "/subscriptions/dd4bfc94-a096-412b-9c43-4bd13e35afbc/resourcegroups/QueryResourceGroupName/providers/microsoft.insights/scheduledqueryrules/heartbeat",
  "name": "heartbeat",
  "type": "microsoft.insights/scheduledqueryrules",
  "location": "eastus",
  "tags": {},
  "properties": {
    "description": "Health check rule",
    "severity": 4,
    "enabled": true,
    "evaluationFrequency": "PT5M",
    "scopes": [
      "/subscriptions/aaf177ed-1330-a9f2-80ea-fd3d7783b147/resourceGroups/scopeResourceGroup1"
    ],
    "targetResourceTypes": [
      "Microsoft.Compute/virtualMachines"
    ],
    "windowSize": "PT10M",
    "criteria": {
      "allOf": [
        {
          "query": "Heartbeat",
          "timeAggregation": "Count",
          "dimensions": [],
          "operator": "GreaterThan",
          "threshold": 360,
          "failingPeriods": {
            "numberOfEvaluationPeriods": 1,
            "minFailingPeriodsToAlert": 1
          }
        }
      ]
    },
    "muteActionsDuration": "PT30M",
    "actions": {
      "actionGroups": [
        "/subscriptions/1cf177ed-1330-4692-80ea-fd3d7783b147/resourcegroups/sqrapi/providers/microsoft.insights/actiongroups/myactiongroup"
      ],
      "customProperties": {
        "key11": "value11",
        "key12": "value12"
      }
    },
    "autoMitigate": true,
    "isWorkspaceAlertsStorageConfigured": true,
    "checkWorkspaceAlertsStorageConfigured": true,
    "skipQueryValidation": true
  }
}
{
  "id": "/subscriptions/dd4bfc94-a096-412b-9c43-4bd13e35afbc/resourcegroups/QueryResourceGroupName/providers/microsoft.insights/scheduledqueryrules/heartbeat",
  "name": "heartbeat",
  "type": "microsoft.insights/scheduledqueryrules",
  "location": "eastus",
  "tags": {},
  "properties": {
    "description": "Health check rule",
    "severity": 4,
    "enabled": true,
    "evaluationFrequency": "PT5M",
    "scopes": [
      "/subscriptions/aaf177ed-1330-a9f2-80ea-fd3d7783b147/resourceGroups/scopeResourceGroup1"
    ],
    "targetResourceTypes": [
      "Microsoft.Compute/virtualMachines"
    ],
    "windowSize": "PT10M",
    "criteria": {
      "allOf": [
        {
          "query": "Heartbeat",
          "timeAggregation": "Count",
          "dimensions": [],
          "operator": "GreaterThan",
          "threshold": 360,
          "failingPeriods": {
            "numberOfEvaluationPeriods": 1,
            "minFailingPeriodsToAlert": 1
          }
        }
      ]
    },
    "muteActionsDuration": "PT30M",
    "actions": {
      "actionGroups": [
        "/subscriptions/1cf177ed-1330-4692-80ea-fd3d7783b147/resourcegroups/sqrapi/providers/microsoft.insights/actiongroups/myactiongroup"
      ],
      "customProperties": {
        "key11": "value11",
        "key12": "value12"
      }
    },
    "autoMitigate": true,
    "isWorkspaceAlertsStorageConfigured": true,
    "checkWorkspaceAlertsStorageConfigured": true,
    "skipQueryValidation": true
  }
}

Create or update a scheduled query rule on Subscription

Sample Request

PUT https://management.azure.com/subscriptions/dd4bfc94-a096-412b-9c43-4bd13e35afbc/resourceGroups/QueryResourceGroupName/providers/Microsoft.Insights/scheduledQueryRules/perf?api-version=2021-08-01

{
  "location": "eastus",
  "properties": {
    "description": "Performance rule",
    "severity": 4,
    "enabled": true,
    "evaluationFrequency": "PT5M",
    "scopes": [
      "/subscriptions/aaf177ed-1330-a9f2-80ea-fd3d7783b147"
    ],
    "targetResourceTypes": [
      "Microsoft.Compute/virtualMachines"
    ],
    "windowSize": "PT10M",
    "criteria": {
      "allOf": [
        {
          "query": "Perf | where ObjectName == \"Processor\"",
          "timeAggregation": "Average",
          "metricMeasureColumn": "% Processor Time",
          "resourceIdColumn": "resourceId",
          "dimensions": [
            {
              "name": "ComputerIp",
              "operator": "Exclude",
              "values": [
                "192.168.1.1"
              ]
            },
            {
              "name": "OSType",
              "operator": "Include",
              "values": [
                "*"
              ]
            }
          ],
          "operator": "GreaterThan",
          "threshold": 70,
          "failingPeriods": {
            "numberOfEvaluationPeriods": 1,
            "minFailingPeriodsToAlert": 1
          }
        }
      ]
    },
    "muteActionsDuration": "PT30M",
    "actions": {
      "actionGroups": [
        "/subscriptions/1cf177ed-1330-4692-80ea-fd3d7783b147/resourcegroups/sqrapi/providers/microsoft.insights/actiongroups/myactiongroup"
      ],
      "customProperties": {
        "key11": "value11",
        "key12": "value12"
      }
    },
    "autoMitigate": true,
    "checkWorkspaceAlertsStorageConfigured": true,
    "skipQueryValidation": true
  }
}

Sample Response

{
  "id": "/subscriptions/dd4bfc94-a096-412b-9c43-4bd13e35afbc/resourcegroups/QueryResourceGroupName/providers/microsoft.insights/scheduledqueryrules/perf",
  "name": "perf",
  "type": "microsoft.insights/scheduledqueryrules",
  "location": "eastus",
  "tags": {},
  "properties": {
    "description": "Performance rule",
    "severity": 4,
    "enabled": true,
    "evaluationFrequency": "PT5M",
    "scopes": [
      "/subscriptions/aaf177ed-1330-a9f2-80ea-fd3d7783b147"
    ],
    "targetResourceTypes": [
      "Microsoft.Compute/virtualMachines"
    ],
    "windowSize": "PT10M",
    "criteria": {
      "allOf": [
        {
          "query": "Perf | where ObjectName == \"Processor\"",
          "timeAggregation": "Average",
          "metricMeasureColumn": "% Processor Time",
          "resourceIdColumn": "resourceId",
          "dimensions": [
            {
              "name": "ComputerIp",
              "operator": "Exclude",
              "values": [
                "192.168.1.1"
              ]
            },
            {
              "name": "OSType",
              "operator": "Include",
              "values": [
                "*"
              ]
            }
          ],
          "operator": "GreaterThan",
          "threshold": 70,
          "failingPeriods": {
            "numberOfEvaluationPeriods": 1,
            "minFailingPeriodsToAlert": 1
          }
        }
      ]
    },
    "muteActionsDuration": "PT30M",
    "actions": {
      "actionGroups": [
        "/subscriptions/1cf177ed-1330-4692-80ea-fd3d7783b147/resourcegroups/sqrapi/providers/microsoft.insights/actiongroups/myactiongroup"
      ],
      "customProperties": {
        "key11": "value11",
        "key12": "value12"
      }
    },
    "autoMitigate": true,
    "isWorkspaceAlertsStorageConfigured": true,
    "checkWorkspaceAlertsStorageConfigured": true,
    "skipQueryValidation": true
  }
}
{
  "id": "/subscriptions/dd4bfc94-a096-412b-9c43-4bd13e35afbc/resourcegroups/QueryResourceGroupName/providers/microsoft.insights/scheduledqueryrules/perf",
  "name": "perf",
  "type": "microsoft.insights/scheduledqueryrules",
  "location": "eastus",
  "tags": {},
  "properties": {
    "description": "Performance rule",
    "severity": 4,
    "enabled": true,
    "evaluationFrequency": "PT5M",
    "scopes": [
      "/subscriptions/aaf177ed-1330-a9f2-80ea-fd3d7783b147"
    ],
    "targetResourceTypes": [
      "Microsoft.Compute/virtualMachines"
    ],
    "windowSize": "PT10M",
    "criteria": {
      "allOf": [
        {
          "query": "Perf | where ObjectName == \"Processor\"",
          "timeAggregation": "Average",
          "metricMeasureColumn": "% Processor Time",
          "resourceIdColumn": "resourceId",
          "dimensions": [
            {
              "name": "ComputerIp",
              "operator": "Exclude",
              "values": [
                "192.168.1.1"
              ]
            },
            {
              "name": "OSType",
              "operator": "Include",
              "values": [
                "*"
              ]
            }
          ],
          "operator": "GreaterThan",
          "threshold": 70,
          "failingPeriods": {
            "numberOfEvaluationPeriods": 1,
            "minFailingPeriodsToAlert": 1
          }
        }
      ]
    },
    "muteActionsDuration": "PT30M",
    "actions": {
      "actionGroups": [
        "/subscriptions/1cf177ed-1330-4692-80ea-fd3d7783b147/resourcegroups/sqrapi/providers/microsoft.insights/actiongroups/myactiongroup"
      ],
      "customProperties": {
        "key11": "value11",
        "key12": "value12"
      }
    },
    "autoMitigate": true,
    "isWorkspaceAlertsStorageConfigured": true,
    "checkWorkspaceAlertsStorageConfigured": true,
    "skipQueryValidation": true
  }
}

정의

Name Description
Actions

경고가 발생할 때 호출하는 작업입니다.

AlertSeverity

경고의 심각도입니다. [0-4] 사이의 정수여야 합니다. 값 0이 가장 심각합니다. LogAlert 종류의 규칙에만 관련되고 필요합니다.

Condition

예약된 쿼리 규칙의 조건입니다.

conditionOperator

criteria 연산자입니다. LogAlert 종류의 규칙에만 관련되고 필요합니다.

createdByType

리소스를 만든 ID 유형입니다.

Dimension

차원 분할 및 필터링 정의

dimensionOperator

차원 값에 대한 연산자

ErrorAdditionalInfo

리소스 관리 오류 추가 정보입니다.

ErrorContract

오류 응답의 형식을 설명합니다.

ErrorResponse

오류 응답

FailingPeriods

경고를 발생에 필요한 선택한 조회 기간 내에 필요한 최소 위반 횟수입니다. LogAlert 종류의 규칙에만 관련됩니다.

Kind

예약된 쿼리 규칙의 유형을 나타냅니다. 기본값은 LogAlert입니다.

ScheduledQueryRuleCriteria

예약된 쿼리 규칙의 조건을 정의하는 규칙 조건입니다.

ScheduledQueryRuleResource

예약된 쿼리 규칙 리소스입니다.

systemData

리소스 만들기 및 마지막 수정과 관련된 메타데이터입니다.

timeAggregation

집계 형식. LogAlert 종류의 규칙에만 관련되고 필요합니다.

Actions

경고가 발생할 때 호출하는 작업입니다.

Name 형식 Description
actionGroups

string[]

경고가 발생할 때 호출할 작업 그룹 리소스 ID입니다.

customProperties

object

경고 페이로드의 속성입니다.

AlertSeverity

경고의 심각도입니다. [0-4] 사이의 정수여야 합니다. 값 0이 가장 심각합니다. LogAlert 종류의 규칙에만 관련되고 필요합니다.

Name 형식 Description
0

Integer

1

Integer

2

Integer

3

Integer

4

Integer

Condition

예약된 쿼리 규칙의 조건입니다.

Name 형식 Description
dimensions

Dimension[]

차원 조건 목록

failingPeriods

FailingPeriods

경고를 발생에 필요한 선택한 조회 기간 내에 필요한 최소 위반 횟수입니다. LogAlert 종류의 규칙에만 관련됩니다.

metricMeasureColumn

string

메트릭 측정값 번호를 포함하는 열입니다. LogAlert 종류의 규칙에만 관련됩니다.

metricName

string

보낼 메트릭의 이름입니다. LogToMetric 종류의 규칙에만 관련되고 필요합니다.

operator

conditionOperator

criteria 연산자입니다. LogAlert 종류의 규칙에만 관련되고 필요합니다.

query

string

로그 쿼리 경고

resourceIdColumn

string

리소스 ID를 포함하는 열입니다. 열의 콘텐츠는 리소스 ID로 형식이 지정된 uri여야 합니다. LogAlert 종류의 규칙에만 관련됩니다.

threshold

number

경고를 활성화하는 조건 임계값입니다. LogAlert 종류의 규칙에만 관련되고 필요합니다.

timeAggregation

timeAggregation

집계 형식. LogAlert 종류의 규칙에만 관련되고 필요합니다.

conditionOperator

criteria 연산자입니다. LogAlert 종류의 규칙에만 관련되고 필요합니다.

Name 형식 Description
Equals

string

GreaterThan

string

GreaterThanOrEqual

string

LessThan

string

LessThanOrEqual

string

createdByType

리소스를 만든 ID 유형입니다.

Name 형식 Description
Application

string

Key

string

ManagedIdentity

string

User

string

Dimension

차원 분할 및 필터링 정의

Name 형식 Description
name

string

차원의 이름

operator

dimensionOperator

차원 값에 대한 연산자

values

string[]

차원 값 목록

dimensionOperator

차원 값에 대한 연산자

Name 형식 Description
Exclude

string

Include

string

ErrorAdditionalInfo

리소스 관리 오류 추가 정보입니다.

Name 형식 Description
info

object

추가 정보입니다.

type

string

추가 정보 유형입니다.

ErrorContract

오류 응답의 형식을 설명합니다.

Name 형식 Description
error

ErrorResponse

오류 응답
오류 세부 정보입니다.

ErrorResponse

오류 응답

Name 형식 Description
additionalInfo

ErrorAdditionalInfo[]

오류 추가 정보입니다.

code

string

오류 코드입니다.

details

ErrorResponse[]

오류 세부 정보입니다.

message

string

오류 메시지입니다.

target

string

오류 대상입니다.

FailingPeriods

경고를 발생에 필요한 선택한 조회 기간 내에 필요한 최소 위반 횟수입니다. LogAlert 종류의 규칙에만 관련됩니다.

Name 형식 기본값 Description
minFailingPeriodsToAlert

integer

1

경고를 트리거하는 위반 횟수입니다. numberOfEvaluationPeriods와 작거나 같아야 합니다. 기본값은 1입니다.

numberOfEvaluationPeriods

integer

1

집계된 조회 지점의 수입니다. 조회 기간은 집계 세분성(windowSize) 및 선택한 집계 지점 수를 기준으로 계산됩니다. 기본값은 1입니다.

Kind

예약된 쿼리 규칙의 유형을 나타냅니다. 기본값은 LogAlert입니다.

Name 형식 Description
LogAlert

string

LogToMetric

string

ScheduledQueryRuleCriteria

예약된 쿼리 규칙의 조건을 정의하는 규칙 조건입니다.

Name 형식 Description
allOf

Condition[]

지정된 범위에 대해 평가할 조건 목록

ScheduledQueryRuleResource

예약된 쿼리 규칙 리소스입니다.

Name 형식 Description
etag

string

etag 필드는 필요하지 않습니다 . 응답 본문에 제공된 경우 일반적인 etag 규칙에 따라 헤더로도 제공해야 합니다. 엔터티 태그는 동일한 요청된 리소스에서 두 개 이상의 엔터티를 비교하는 데 사용됩니다. HTTP/1.1은 etag(섹션 14.19), If-Match(섹션 14.24), If-None-Match(섹션 14.26) 및 If-Range(섹션 14.27) 헤더 필드에 엔터티 태그를 사용합니다.

id

string

리소스에 대한 정규화된 리소스 ID입니다. 예 - /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}

kind

Kind

예약된 쿼리 규칙의 유형을 나타냅니다. 기본값은 LogAlert입니다.

location

string

리소스가 있는 지리적 위치

name

string

리소스의 이름입니다.

properties.actions

Actions

경고가 발생할 때 호출하는 작업입니다.

properties.autoMitigate

boolean

경고를 자동으로 해결해야 하는지 여부를 나타내는 플래그입니다. 기본값은 true입니다. LogAlert 종류의 규칙에만 관련됩니다.

properties.checkWorkspaceAlertsStorageConfigured

boolean

이 예약된 쿼리 규칙을 고객의 스토리지에 저장해야 하는지 여부를 나타내는 플래그입니다. 기본값은 false입니다. LogAlert 종류의 규칙에만 관련됩니다.

properties.createdWithApiVersion

string

이 경고 규칙을 만들 때 사용되는 api 버전

properties.criteria

ScheduledQueryRuleCriteria

예약된 쿼리 규칙의 조건을 정의하는 규칙 조건입니다.

properties.description

string

예약된 쿼리 규칙에 대한 설명입니다.

properties.displayName

string

경고 규칙의 표시 이름

properties.enabled

boolean

이 예약된 쿼리 규칙을 사용할 수 있는지 여부를 나타내는 플래그입니다. 값은 true 또는 false여야 합니다.

properties.evaluationFrequency

string

예약된 쿼리 규칙이 ISO 8601 기간 형식으로 표시되는 빈도입니다. LogAlert 종류의 규칙에만 관련되고 필요합니다.

properties.isLegacyLogAnalyticsRule

boolean

True이면 경고 규칙이 레거시 Log Analytic 규칙입니다.

properties.isWorkspaceAlertsStorageConfigured

boolean

예약된 이 쿼리 규칙이 고객의 스토리지에 저장되도록 구성되었는지 여부를 나타내는 플래그입니다. 기본값은 false입니다.

properties.muteActionsDuration

string

경고가 발생한 후 선택한 기간(ISO 8601 기간 형식)에 대한 작업을 음소거합니다. LogAlert 종류의 규칙에만 관련됩니다.

properties.overrideQueryTimeRange

string

지정된 경우 쿼리 시간 범위를 재정의합니다(기본값은 WindowSize*NumberOfEvaluationPeriods). LogAlert 종류의 규칙에만 관련됩니다.

properties.scopes

string[]

이 예약된 쿼리 규칙의 범위가 지정된 리소스 ID 목록입니다.

properties.severity

AlertSeverity

경고의 심각도입니다. [0-4] 사이의 정수여야 합니다. 값 0이 가장 심각합니다. LogAlert 종류의 규칙에만 관련되고 필요합니다.

properties.skipQueryValidation

boolean

제공된 쿼리의 유효성을 검사해야 하는지 여부를 나타내는 플래그입니다. 기본값은 false입니다. LogAlert 종류의 규칙에만 관련됩니다.

properties.targetResourceTypes

string[]

경고가 생성/업데이트되는 대상 리소스의 리소스 종류 목록입니다. 예를 들어 scope 리소스 그룹이고 targetResourceTypes가 Microsoft.Compute/virtualMachines인 경우 경고 조건을 충족하는 리소스 그룹의 각 가상 머신에 대해 다른 경고가 발생합니다. LogAlert 종류의 규칙에만 관련

properties.windowSize

string

경고 쿼리가 실행될 기간(ISO 8601 기간 형식)(bin 크기)입니다. LogAlert 종류의 규칙에만 관련되고 필요합니다.

systemData

systemData

ScheduledQueryRule의 SystemData입니다.

tags

object

리소스 태그.

type

string

리소스 형식입니다. 예: "Microsoft.Compute/virtualMachines" 또는 "Microsoft.Storage/storageAccounts"

systemData

리소스 만들기 및 마지막 수정과 관련된 메타데이터입니다.

Name 형식 Description
createdAt

string

UTC(리소스 만들기)의 타임스탬프입니다.

createdBy

string

리소스를 만든 ID입니다.

createdByType

createdByType

리소스를 만든 ID 유형입니다.

lastModifiedAt

string

리소스 마지막 수정의 타임스탬프(UTC)

lastModifiedBy

string

리소스를 마지막으로 수정한 ID입니다.

lastModifiedByType

createdByType

리소스를 마지막으로 수정한 ID 유형입니다.

timeAggregation

집계 형식. LogAlert 종류의 규칙에만 관련되고 필요합니다.

Name 형식 Description
Average

string

Count

string

Maximum

string

Minimum

string

Total

string