@@ -60,6 +60,26 @@ export interface ScaleCapacity {
6060 default : string ;
6161}
6262
63+ /**
64+ * Specifies an auto scale rule metric dimension.
65+ */
66+ export interface ScaleRuleMetricDimension {
67+ /**
68+ * Name of the dimension.
69+ */
70+ dimensionName : string ;
71+ /**
72+ * the dimension operator. Only 'Equals' and 'NotEquals' are supported. 'Equals' being equal to
73+ * any of the values. 'NotEquals' being not equal to all of the values. Possible values include:
74+ * 'Equals', 'NotEquals'
75+ */
76+ operator : ScaleRuleMetricDimensionOperationType ;
77+ /**
78+ * list of dimension values. For example: ["App1","App2"].
79+ */
80+ values : string [ ] ;
81+ }
82+
6383/**
6484 * The trigger that results in a scaling action.
6585 */
@@ -68,6 +88,10 @@ export interface MetricTrigger {
6888 * the name of the metric that defines what the rule monitors.
6989 */
7090 metricName : string ;
91+ /**
92+ * the namespace of the metric that defines what the rule monitors.
93+ */
94+ metricNamespace ?: string ;
7195 /**
7296 * the resource identifier of the resource the rule monitors.
7397 */
@@ -104,6 +128,11 @@ export interface MetricTrigger {
104128 * the threshold of the metric that triggers the scale action.
105129 */
106130 threshold : number ;
131+ /**
132+ * List of dimension conditions. For example:
133+ * [{"DimensionName":"AppName","Operator":"Equals","Values":["App1"]},{"DimensionName":"Deployment","Operator":"Equals","Values":["default"]}].
134+ */
135+ dimensions ?: ScaleRuleMetricDimension [ ] ;
107136}
108137
109138/**
@@ -2113,13 +2142,13 @@ export interface MetricAlertAction {
21132142 /**
21142143 * The properties of a webhook object.
21152144 */
2116- webhookProperties ?: { [ propertyName : string ] : string } ;
2145+ webHookProperties ?: { [ propertyName : string ] : string } ;
21172146}
21182147
21192148/**
21202149 * Contains the possible cases for MetricAlertCriteria.
21212150 */
2122- export type MetricAlertCriteriaUnion = MetricAlertCriteria | MetricAlertSingleResourceMultipleMetricCriteria | MetricAlertMultipleResourceMultipleMetricCriteria ;
2151+ export type MetricAlertCriteriaUnion = MetricAlertCriteria | MetricAlertSingleResourceMultipleMetricCriteria | WebtestLocationAvailabilityCriteria | MetricAlertMultipleResourceMultipleMetricCriteria ;
21232152
21242153/**
21252154 * The rule criteria that defines the conditions of the alert rule.
@@ -2179,7 +2208,7 @@ export interface MetricAlertResource extends Resource {
21792208 */
21802209 criteria : MetricAlertCriteriaUnion ;
21812210 /**
2182- * the flag that indicates whether the alert should be auto resolved or not.
2211+ * the flag that indicates whether the alert should be auto resolved or not. The default is true.
21832212 */
21842213 autoMitigate ?: boolean ;
21852214 /**
@@ -2242,7 +2271,7 @@ export interface MetricAlertResourcePatch {
22422271 */
22432272 criteria : MetricAlertCriteriaUnion ;
22442273 /**
2245- * the flag that indicates whether the alert should be auto resolved or not.
2274+ * the flag that indicates whether the alert should be auto resolved or not. The default is true.
22462275 */
22472276 autoMitigate ?: boolean ;
22482277 /**
@@ -2340,6 +2369,11 @@ export interface MultiMetricCriteria {
23402369 * List of dimension conditions.
23412370 */
23422371 dimensions ?: MetricDimension [ ] ;
2372+ /**
2373+ * Allows creating an alert rule on a custom metric that isn't yet emitted, by causing the metric
2374+ * validation to be skipped.
2375+ */
2376+ skipMetricValidation ?: boolean ;
23432377 /**
23442378 * Describes unknown properties. The value of an unknown property can be of "any" type.
23452379 */
@@ -2375,9 +2409,15 @@ export interface MetricCriteria {
23752409 */
23762410 dimensions ?: MetricDimension [ ] ;
23772411 /**
2378- * the criteria operator.
2412+ * Allows creating an alert rule on a custom metric that isn't yet emitted, by causing the metric
2413+ * validation to be skipped.
23792414 */
2380- operator : any ;
2415+ skipMetricValidation ?: boolean ;
2416+ /**
2417+ * the criteria operator. Possible values include: 'Equals', 'NotEquals', 'GreaterThan',
2418+ * 'GreaterThanOrEqual', 'LessThan', 'LessThanOrEqual'
2419+ */
2420+ operator : Operator ;
23812421 /**
23822422 * the criteria threshold value that activates the alert.
23832423 */
@@ -2398,6 +2438,28 @@ export interface MetricAlertSingleResourceMultipleMetricCriteria {
23982438 allOf ?: MetricCriteria [ ] ;
23992439}
24002440
2441+ /**
2442+ * Specifies the metric alert rule criteria for a web test resource.
2443+ */
2444+ export interface WebtestLocationAvailabilityCriteria {
2445+ /**
2446+ * Polymorphic Discriminator
2447+ */
2448+ odatatype : "Microsoft.Azure.Monitor.WebtestLocationAvailabilityCriteria" ;
2449+ /**
2450+ * The Application Insights web test Id.
2451+ */
2452+ webTestId : string ;
2453+ /**
2454+ * The Application Insights resource Id.
2455+ */
2456+ componentId : string ;
2457+ /**
2458+ * The number of failed locations.
2459+ */
2460+ failedLocationCount : number ;
2461+ }
2462+
24012463/**
24022464 * Specifies a metric dimension.
24032465 */
@@ -2476,14 +2538,20 @@ export interface DynamicMetricCriteria {
24762538 */
24772539 dimensions ?: MetricDimension [ ] ;
24782540 /**
2479- * The operator used to compare the metric value against the threshold.
2541+ * Allows creating an alert rule on a custom metric that isn't yet emitted, by causing the metric
2542+ * validation to be skipped.
2543+ */
2544+ skipMetricValidation ?: boolean ;
2545+ /**
2546+ * The operator used to compare the metric value against the threshold. Possible values include:
2547+ * 'GreaterThan', 'LessThan', 'GreaterOrLessThan'
24802548 */
2481- operator : any ;
2549+ operator : DynamicThresholdOperator ;
24822550 /**
24832551 * The extent of deviation required to trigger an alert. This will affect how tight the threshold
2484- * is to the metric series pattern.
2552+ * is to the metric series pattern. Possible values include: 'Low', 'Medium', 'High'
24852553 */
2486- alertSensitivity : any ;
2554+ alertSensitivity : DynamicThresholdSensitivity ;
24872555 /**
24882556 * The minimum number of violations required within the selected lookback time window required to
24892557 * raise an alert.
@@ -3233,6 +3301,14 @@ export type TimeAggregationType = 'Average' | 'Minimum' | 'Maximum' | 'Total' |
32333301 */
32343302export type ComparisonOperationType = 'Equals' | 'NotEquals' | 'GreaterThan' | 'GreaterThanOrEqual' | 'LessThan' | 'LessThanOrEqual' ;
32353303
3304+ /**
3305+ * Defines values for ScaleRuleMetricDimensionOperationType.
3306+ * Possible values include: 'Equals', 'NotEquals'
3307+ * @readonly
3308+ * @enum {string}
3309+ */
3310+ export type ScaleRuleMetricDimensionOperationType = 'Equals' | 'NotEquals' ;
3311+
32363312/**
32373313 * Defines values for ScaleDirection.
32383314 * Possible values include: 'None', 'Increase', 'Decrease'
@@ -3331,6 +3407,31 @@ export type Sensitivity = 'Low' | 'Medium' | 'High';
33313407 */
33323408export type BaselineSensitivity = 'Low' | 'Medium' | 'High' ;
33333409
3410+ /**
3411+ * Defines values for Operator.
3412+ * Possible values include: 'Equals', 'NotEquals', 'GreaterThan', 'GreaterThanOrEqual', 'LessThan',
3413+ * 'LessThanOrEqual'
3414+ * @readonly
3415+ * @enum {string}
3416+ */
3417+ export type Operator = 'Equals' | 'NotEquals' | 'GreaterThan' | 'GreaterThanOrEqual' | 'LessThan' | 'LessThanOrEqual' ;
3418+
3419+ /**
3420+ * Defines values for DynamicThresholdOperator.
3421+ * Possible values include: 'GreaterThan', 'LessThan', 'GreaterOrLessThan'
3422+ * @readonly
3423+ * @enum {string}
3424+ */
3425+ export type DynamicThresholdOperator = 'GreaterThan' | 'LessThan' | 'GreaterOrLessThan' ;
3426+
3427+ /**
3428+ * Defines values for DynamicThresholdSensitivity.
3429+ * Possible values include: 'Low', 'Medium', 'High'
3430+ * @readonly
3431+ * @enum {string}
3432+ */
3433+ export type DynamicThresholdSensitivity = 'Low' | 'Medium' | 'High' ;
3434+
33343435/**
33353436 * Defines values for Enabled.
33363437 * Possible values include: 'true', 'false'
0 commit comments