Share via


ArmMonitorModelFactory.ScheduledQueryRuleData Method

Definition

Initializes a new instance of ScheduledQueryRuleData.

public static Azure.ResourceManager.Monitor.ScheduledQueryRuleData ScheduledQueryRuleData (Azure.Core.ResourceIdentifier id = default, string name = default, Azure.Core.ResourceType resourceType = default, Azure.ResourceManager.Models.SystemData systemData = default, System.Collections.Generic.IDictionary<string,string> tags = default, Azure.Core.AzureLocation location = default, Azure.ResourceManager.Monitor.Models.ScheduledQueryRuleKind? kind = default, Azure.ETag? etag = default, string createdWithApiVersion = default, bool? isLegacyLogAnalyticsRule = default, string description = default, string displayName = default, Azure.ResourceManager.Monitor.Models.AlertSeverity? severity = default, bool? isEnabled = default, System.Collections.Generic.IEnumerable<string> scopes = default, TimeSpan? evaluationFrequency = default, TimeSpan? windowSize = default, TimeSpan? overrideQueryTimeRange = default, System.Collections.Generic.IEnumerable<string> targetResourceTypes = default, System.Collections.Generic.IEnumerable<Azure.ResourceManager.Monitor.Models.ScheduledQueryRuleCondition> criteriaAllOf = default, TimeSpan? muteActionsDuration = default, Azure.ResourceManager.Monitor.Models.ScheduledQueryRuleActions actions = default, bool? isWorkspaceAlertsStorageConfigured = default, bool? checkWorkspaceAlertsStorageConfigured = default, bool? skipQueryValidation = default, bool? autoMitigate = default);
static member ScheduledQueryRuleData : Azure.Core.ResourceIdentifier * string * Azure.Core.ResourceType * Azure.ResourceManager.Models.SystemData * System.Collections.Generic.IDictionary<string, string> * Azure.Core.AzureLocation * Nullable<Azure.ResourceManager.Monitor.Models.ScheduledQueryRuleKind> * Nullable<Azure.ETag> * string * Nullable<bool> * string * string * Nullable<Azure.ResourceManager.Monitor.Models.AlertSeverity> * Nullable<bool> * seq<string> * Nullable<TimeSpan> * Nullable<TimeSpan> * Nullable<TimeSpan> * seq<string> * seq<Azure.ResourceManager.Monitor.Models.ScheduledQueryRuleCondition> * Nullable<TimeSpan> * Azure.ResourceManager.Monitor.Models.ScheduledQueryRuleActions * Nullable<bool> * Nullable<bool> * Nullable<bool> * Nullable<bool> -> Azure.ResourceManager.Monitor.ScheduledQueryRuleData
Public Shared Function ScheduledQueryRuleData (Optional id As ResourceIdentifier = Nothing, Optional name As String = Nothing, Optional resourceType As ResourceType = Nothing, Optional systemData As SystemData = Nothing, Optional tags As IDictionary(Of String, String) = Nothing, Optional location As AzureLocation = Nothing, Optional kind As Nullable(Of ScheduledQueryRuleKind) = Nothing, Optional etag As Nullable(Of ETag) = Nothing, Optional createdWithApiVersion As String = Nothing, Optional isLegacyLogAnalyticsRule As Nullable(Of Boolean) = Nothing, Optional description As String = Nothing, Optional displayName As String = Nothing, Optional severity As Nullable(Of AlertSeverity) = Nothing, Optional isEnabled As Nullable(Of Boolean) = Nothing, Optional scopes As IEnumerable(Of String) = Nothing, Optional evaluationFrequency As Nullable(Of TimeSpan) = Nothing, Optional windowSize As Nullable(Of TimeSpan) = Nothing, Optional overrideQueryTimeRange As Nullable(Of TimeSpan) = Nothing, Optional targetResourceTypes As IEnumerable(Of String) = Nothing, Optional criteriaAllOf As IEnumerable(Of ScheduledQueryRuleCondition) = Nothing, Optional muteActionsDuration As Nullable(Of TimeSpan) = Nothing, Optional actions As ScheduledQueryRuleActions = Nothing, Optional isWorkspaceAlertsStorageConfigured As Nullable(Of Boolean) = Nothing, Optional checkWorkspaceAlertsStorageConfigured As Nullable(Of Boolean) = Nothing, Optional skipQueryValidation As Nullable(Of Boolean) = Nothing, Optional autoMitigate As Nullable(Of Boolean) = Nothing) As ScheduledQueryRuleData

Parameters

id
ResourceIdentifier

The id.

name
String

The name.

resourceType
ResourceType

The resourceType.

systemData
SystemData

The systemData.

tags
IDictionary<String,String>

The tags.

location
AzureLocation

The location.

kind
Nullable<ScheduledQueryRuleKind>

Indicates the type of scheduled query rule. The default is LogAlert.

etag
Nullable<ETag>

The etag field is not required. If it is provided in the response body, it must also be provided as a header per the normal etag convention. Entity tags are used for comparing two or more entities from the same requested resource. HTTP/1.1 uses entity tags in the etag (section 14.19), If-Match (section 14.24), If-None-Match (section 14.26), and If-Range (section 14.27) header fields.

createdWithApiVersion
String

The api-version used when creating this alert rule.

isLegacyLogAnalyticsRule
Nullable<Boolean>

True if alert rule is legacy Log Analytic rule.

description
String

The description of the scheduled query rule.

displayName
String

The display name of the alert rule.

severity
Nullable<AlertSeverity>

Severity of the alert. Should be an integer between [0-4]. Value of 0 is severest. Relevant and required only for rules of the kind LogAlert.

isEnabled
Nullable<Boolean>

The flag which indicates whether this scheduled query rule is enabled. Value should be true or false.

scopes
IEnumerable<String>

The list of resource id's that this scheduled query rule is scoped to.

evaluationFrequency
Nullable<TimeSpan>

How often the scheduled query rule is evaluated represented in ISO 8601 duration format. Relevant and required only for rules of the kind LogAlert.

windowSize
Nullable<TimeSpan>

The period of time (in ISO 8601 duration format) on which the Alert query will be executed (bin size). Relevant and required only for rules of the kind LogAlert.

overrideQueryTimeRange
Nullable<TimeSpan>

If specified then overrides the query time range (default is WindowSize*NumberOfEvaluationPeriods). Relevant only for rules of the kind LogAlert.

targetResourceTypes
IEnumerable<String>

List of resource type of the target resource(s) on which the alert is created/updated. For example if the scope is a resource group and targetResourceTypes is Microsoft.Compute/virtualMachines, then a different alert will be fired for each virtual machine in the resource group which meet the alert criteria. Relevant only for rules of the kind LogAlert.

criteriaAllOf
IEnumerable<ScheduledQueryRuleCondition>

The rule criteria that defines the conditions of the scheduled query rule.

muteActionsDuration
Nullable<TimeSpan>

Mute actions for the chosen period of time (in ISO 8601 duration format) after the alert is fired. Relevant only for rules of the kind LogAlert.

actions
ScheduledQueryRuleActions

Actions to invoke when the alert fires.

isWorkspaceAlertsStorageConfigured
Nullable<Boolean>

The flag which indicates whether this scheduled query rule has been configured to be stored in the customer's storage. The default is false.

checkWorkspaceAlertsStorageConfigured
Nullable<Boolean>

The flag which indicates whether this scheduled query rule should be stored in the customer's storage. The default is false. Relevant only for rules of the kind LogAlert.

skipQueryValidation
Nullable<Boolean>

The flag which indicates whether the provided query should be validated or not. The default is false. Relevant only for rules of the kind LogAlert.

autoMitigate
Nullable<Boolean>

The flag that indicates whether the alert should be automatically resolved or not. The default is true. Relevant only for rules of the kind LogAlert.

Returns

A new ScheduledQueryRuleData instance for mocking.

Applies to