-
Notifications
You must be signed in to change notification settings - Fork 5.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Liran e alertsmanagement microsoft.alerts management 2024 03 01 previ…
…ew (#27738) * Adds base for updating Microsoft.AlertsManagement from version preview/2023-05-01-preview to version 2024-03-01-preview * Updates readme * Updates API version in new specs and examples * API 2024-03-01-preview: CorrelationUpdates * prettier check fix attempt * Swagger SemanticValidation fix * Swagger PrettierCheck fix * added suppression for OperationsAPIImplementation * 1. changed default package alertprocessingrules.json 2. other fixes to comments by the reviewer * pr fixes * indentation fix * pr fixes * fixed enum casing --------- Co-authored-by: MIDDLEEAST\lienglender <[email protected]>
- Loading branch information
Showing
15 changed files
with
2,346 additions
and
5 deletions.
There are no files selected for viewing
911 changes: 911 additions & 0 deletions
911
...e-manager/Microsoft.AlertsManagement/preview/2024-03-01-preview/AlertProcessingRules.json
Large diffs are not rendered by default.
Oops, something went wrong.
93 changes: 93 additions & 0 deletions
93
...es/AlertProcessingRules_Create_or_update_add_action_group_all_alerts_in_subscription.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,93 @@ | ||
{ | ||
"parameters": { | ||
"api-version": "2024-03-01-preview", | ||
"subscriptionId": "subId1", | ||
"resourceGroupName": "alertscorrelationrg", | ||
"alertProcessingRuleName": "AddActionGroupToSubscription", | ||
"alertProcessingRule": { | ||
"location": "Global", | ||
"tags": {}, | ||
"properties": { | ||
"scopes": [ | ||
"/subscriptions/subId1" | ||
], | ||
"actions": [ | ||
{ | ||
"actionType": "AddActionGroups", | ||
"actionGroupIds": [ | ||
"/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/ActionGroup1" | ||
] | ||
} | ||
], | ||
"description": "Add ActionGroup1 to all alerts in the subscription", | ||
"enabled": true | ||
} | ||
} | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"systemData": { | ||
"createdBy": "[email protected]", | ||
"createdByType": "User", | ||
"createdAt": "2021-02-12T22:05:09Z", | ||
"lastModifiedBy": "[email protected]", | ||
"lastModifiedByType": "User", | ||
"lastModifiedAt": "2021-02-13T16:15:34Z" | ||
}, | ||
"properties": { | ||
"scopes": [ | ||
"/subscriptions/subId1" | ||
], | ||
"actions": [ | ||
{ | ||
"actionType": "AddActionGroups", | ||
"actionGroupIds": [ | ||
"/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/ActionGroup1" | ||
] | ||
} | ||
], | ||
"description": "Add ActionGroup1 to all alerts in the subscription", | ||
"enabled": true | ||
}, | ||
"id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/AddActionGroupToSubscription", | ||
"type": "Microsoft.AlertsManagement/actionRules", | ||
"name": "AddActionGroupToSubscription", | ||
"location": "Global", | ||
"tags": {} | ||
} | ||
}, | ||
"201": { | ||
"body": { | ||
"systemData": { | ||
"createdBy": "[email protected]", | ||
"createdByType": "User", | ||
"createdAt": "2021-02-12T22:05:09Z", | ||
"lastModifiedBy": "[email protected]", | ||
"lastModifiedByType": "User", | ||
"lastModifiedAt": "2021-02-13T16:15:34Z" | ||
}, | ||
"properties": { | ||
"scopes": [ | ||
"/subscriptions/subId1" | ||
], | ||
"actions": [ | ||
{ | ||
"actionType": "AddActionGroups", | ||
"actionGroupIds": [ | ||
"/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/ActionGroup1" | ||
] | ||
} | ||
], | ||
"description": "Add ActionGroup1 to all alerts in the subscription", | ||
"enabled": true | ||
}, | ||
"id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/AddActionGroupToSubscription", | ||
"type": "Microsoft.AlertsManagement/actionRules", | ||
"name": "AddActionGroupToSubscription", | ||
"location": "Global", | ||
"tags": {} | ||
} | ||
} | ||
} | ||
} |
108 changes: 108 additions & 0 deletions
108
...ew/2024-03-01-preview/examples/AlertProcessingRules_Create_or_update_add_correlation.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,108 @@ | ||
{ | ||
"parameters": { | ||
"api-version": "2024-03-01-preview", | ||
"subscriptionId": "subId1", | ||
"resourceGroupName": "alertscorrelationrg", | ||
"alertProcessingRuleName": "CorrelateAlerts", | ||
"alertProcessingRule": { | ||
"location": "Global", | ||
"tags": {}, | ||
"properties": { | ||
"scopes": [ | ||
"/subscriptions/subId1" | ||
], | ||
"actions": [ | ||
{ | ||
"actionType": "CorrelateAlerts", | ||
"correlateBy": [ | ||
{ | ||
"field": "essentials.alertRule" | ||
} | ||
], | ||
"correlationInterval": "PT30M", | ||
"priority": 50, | ||
"notificationsForCorrelatedAlerts": "SuppressAlways" | ||
} | ||
], | ||
"description": "Correlate Alerts Example.", | ||
"enabled": true | ||
} | ||
} | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"systemData": { | ||
"createdBy": "[email protected]", | ||
"createdByType": "User", | ||
"createdAt": "2021-02-12T22:05:09Z", | ||
"lastModifiedBy": "[email protected]", | ||
"lastModifiedByType": "User", | ||
"lastModifiedAt": "2021-02-13T16:15:34Z" | ||
}, | ||
"properties": { | ||
"scopes": [ | ||
"/subscriptions/subId1" | ||
], | ||
"actions": [ | ||
{ | ||
"actionType": "CorrelateAlerts", | ||
"correlateBy": [ | ||
{ | ||
"field": "essentials.alertRule" | ||
} | ||
], | ||
"correlationInterval": "PT30M", | ||
"priority": 50, | ||
"notificationsForCorrelatedAlerts": "SuppressAlways" | ||
} | ||
], | ||
"description": "Correlate Alerts Example.", | ||
"enabled": true | ||
}, | ||
"id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/CorrelateAlerts", | ||
"type": "Microsoft.AlertsManagement/actionRules", | ||
"name": "CorrelateAlerts", | ||
"location": "Global", | ||
"tags": {} | ||
} | ||
}, | ||
"201": { | ||
"body": { | ||
"systemData": { | ||
"createdBy": "[email protected]", | ||
"createdByType": "User", | ||
"createdAt": "2021-02-12T22:05:09Z", | ||
"lastModifiedBy": "[email protected]", | ||
"lastModifiedByType": "User", | ||
"lastModifiedAt": "2021-02-13T16:15:34Z" | ||
}, | ||
"properties": { | ||
"scopes": [ | ||
"/subscriptions/subId1" | ||
], | ||
"actions": [ | ||
{ | ||
"actionType": "CorrelateAlerts", | ||
"correlateBy": [ | ||
{ | ||
"field": "essentials.alertRule" | ||
} | ||
], | ||
"correlationInterval": "PT30M", | ||
"priority": 50, | ||
"notificationsForCorrelatedAlerts": "SuppressAlways" | ||
} | ||
], | ||
"description": "Correlate Alerts Example.", | ||
"enabled": true | ||
}, | ||
"id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/CorrelateAlerts", | ||
"type": "Microsoft.AlertsManagement/actionRules", | ||
"name": "CorrelateAlerts", | ||
"location": "Global", | ||
"tags": {} | ||
} | ||
} | ||
} | ||
} |
132 changes: 132 additions & 0 deletions
132
...mples/AlertProcessingRules_Create_or_update_add_correlation_with_correlation_updates.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,132 @@ | ||
{ | ||
"parameters": { | ||
"api-version": "2024-03-01-preview", | ||
"subscriptionId": "subId1", | ||
"resourceGroupName": "alertscorrelationrg", | ||
"alertProcessingRuleName": "CorrelateAlerts", | ||
"alertProcessingRule": { | ||
"location": "Global", | ||
"tags": {}, | ||
"properties": { | ||
"scopes": [ | ||
"/subscriptions/subId1" | ||
], | ||
"actions": [ | ||
{ | ||
"actionType": "CorrelateAlerts", | ||
"correlateBy": [ | ||
{ | ||
"field": "essentials.alertRule" | ||
} | ||
], | ||
"correlationInterval": "PT30M", | ||
"priority": 50, | ||
"notificationsForCorrelatedAlerts": "SuppressAlways", | ||
"correlationUpdates": { | ||
"updateType": "timeBased", | ||
"updateInterval": "PT15M", | ||
"actionGroups": [ | ||
"/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId1", | ||
"/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId2" | ||
] | ||
} | ||
} | ||
], | ||
"description": "Correlate Alerts Example.", | ||
"enabled": true | ||
} | ||
} | ||
}, | ||
"responses": { | ||
"200": { | ||
"body": { | ||
"systemData": { | ||
"createdBy": "[email protected]", | ||
"createdByType": "User", | ||
"createdAt": "2021-02-12T22:05:09Z", | ||
"lastModifiedBy": "[email protected]", | ||
"lastModifiedByType": "User", | ||
"lastModifiedAt": "2021-02-13T16:15:34Z" | ||
}, | ||
"properties": { | ||
"scopes": [ | ||
"/subscriptions/subId1" | ||
], | ||
"actions": [ | ||
{ | ||
"actionType": "CorrelateAlerts", | ||
"correlateBy": [ | ||
{ | ||
"field": "essentials.alertRule" | ||
} | ||
], | ||
"correlationInterval": "PT30M", | ||
"priority": 50, | ||
"notificationsForCorrelatedAlerts": "SuppressAlways", | ||
"correlationUpdates": { | ||
"updateType": "timeBased", | ||
"updateInterval": "PT15M", | ||
"actionGroups": [ | ||
"/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId1", | ||
"/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId2" | ||
] | ||
} | ||
} | ||
], | ||
"description": "Correlate Alerts Example.", | ||
"enabled": true | ||
}, | ||
"id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/CorrelateAlerts", | ||
"type": "Microsoft.AlertsManagement/actionRules", | ||
"name": "CorrelateAlerts", | ||
"location": "Global", | ||
"tags": {} | ||
} | ||
}, | ||
"201": { | ||
"body": { | ||
"systemData": { | ||
"createdBy": "[email protected]", | ||
"createdByType": "User", | ||
"createdAt": "2021-02-12T22:05:09Z", | ||
"lastModifiedBy": "[email protected]", | ||
"lastModifiedByType": "User", | ||
"lastModifiedAt": "2021-02-13T16:15:34Z" | ||
}, | ||
"properties": { | ||
"scopes": [ | ||
"/subscriptions/subId1" | ||
], | ||
"actions": [ | ||
{ | ||
"actionType": "CorrelateAlerts", | ||
"correlateBy": [ | ||
{ | ||
"field": "essentials.alertRule" | ||
} | ||
], | ||
"correlationInterval": "PT30M", | ||
"priority": 50, | ||
"notificationsForCorrelatedAlerts": "SuppressAlways", | ||
"correlationUpdates": { | ||
"updateType": "timeBased", | ||
"updateInterval": "PT15M", | ||
"actionGroups": [ | ||
"/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId1", | ||
"/subscriptions/subId1/resourcegroups/RGId1/providers/microsoft.insights/actiongroups/AGId2" | ||
] | ||
} | ||
} | ||
], | ||
"description": "Correlate Alerts Example.", | ||
"enabled": true | ||
}, | ||
"id": "/subscriptions/subId1/resourceGroups/alertscorrelationrg/providers/Microsoft.AlertsManagement/actionRules/CorrelateAlerts", | ||
"type": "Microsoft.AlertsManagement/actionRules", | ||
"name": "CorrelateAlerts", | ||
"location": "Global", | ||
"tags": {} | ||
} | ||
} | ||
} | ||
} |
Oops, something went wrong.