MetricAlertData Constructors
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
| Name | Description |
|---|---|
| MetricAlertData(AzureLocation, Int32, Boolean, IEnumerable<String>, TimeSpan, MetricAlertCriteria) |
Initializes a new instance of MetricAlertData. |
| MetricAlertData(AzureLocation, Int32, Boolean, IEnumerable<String>, TimeSpan, TimeSpan, MetricAlertCriteria) |
Initializes a new instance of MetricAlertData. |
MetricAlertData(AzureLocation, Int32, Boolean, IEnumerable<String>, TimeSpan, MetricAlertCriteria)
- Source:
- MetricAlertData.cs
Initializes a new instance of MetricAlertData.
public MetricAlertData(Azure.Core.AzureLocation location, int severity, bool isEnabled, System.Collections.Generic.IEnumerable<string> scopes, TimeSpan evaluationFrequency, Azure.ResourceManager.Monitor.Models.MetricAlertCriteria criteria);
new Azure.ResourceManager.Monitor.MetricAlertData : Azure.Core.AzureLocation * int * bool * seq<string> * TimeSpan * Azure.ResourceManager.Monitor.Models.MetricAlertCriteria -> Azure.ResourceManager.Monitor.MetricAlertData
Public Sub New (location As AzureLocation, severity As Integer, isEnabled As Boolean, scopes As IEnumerable(Of String), evaluationFrequency As TimeSpan, criteria As MetricAlertCriteria)
Parameters
- location
- AzureLocation
The geo-location where the resource lives.
- severity
- Int32
Alert severity {0, 1, 2, 3, 4}.
- isEnabled
- Boolean
The flag that indicates whether the metric alert is enabled.
- scopes
- IEnumerable<String>
The list of resource id's that this metric alert is scoped to. You cannot change the scope of a metric rule based on logs.
- evaluationFrequency
- TimeSpan
How often the metric alert is evaluated represented in ISO 8601 duration format.
- criteria
- MetricAlertCriteria
Defines the specific alert criteria information.
Exceptions
scopes or criteria is null.
Applies to
MetricAlertData(AzureLocation, Int32, Boolean, IEnumerable<String>, TimeSpan, TimeSpan, MetricAlertCriteria)
- Source:
- MetricAlertData.cs
- Source:
- MetricAlertData.cs
Initializes a new instance of MetricAlertData.
public MetricAlertData(Azure.Core.AzureLocation location, int severity, bool isEnabled, System.Collections.Generic.IEnumerable<string> scopes, TimeSpan evaluationFrequency, TimeSpan windowSize, Azure.ResourceManager.Monitor.Models.MetricAlertCriteria criteria);
new Azure.ResourceManager.Monitor.MetricAlertData : Azure.Core.AzureLocation * int * bool * seq<string> * TimeSpan * TimeSpan * Azure.ResourceManager.Monitor.Models.MetricAlertCriteria -> Azure.ResourceManager.Monitor.MetricAlertData
Public Sub New (location As AzureLocation, severity As Integer, isEnabled As Boolean, scopes As IEnumerable(Of String), evaluationFrequency As TimeSpan, windowSize As TimeSpan, criteria As MetricAlertCriteria)
Parameters
- location
- AzureLocation
The geo-location where the resource lives.
- severity
- Int32
Alert severity {0, 1, 2, 3, 4}.
- isEnabled
- Boolean
The flag that indicates whether the metric alert is enabled.
- scopes
- IEnumerable<String>
The list of resource id's that this metric alert is scoped to. You cannot change the scope of a metric rule based on logs.
- evaluationFrequency
- TimeSpan
How often the metric alert is evaluated represented in ISO 8601 duration format.
- windowSize
- TimeSpan
The period of time (in ISO 8601 duration format) that is used to monitor alert activity based on the threshold.
- criteria
- MetricAlertCriteria
Defines the specific alert criteria information.
Exceptions
scopes is null.