Alerting: Update GettableRuleGroupConfig and PostableRuleGroupConfig with missing fields supported by Prometheus (#94030)

This commit is contained in:
Yuri Tseretyan
2024-10-01 14:17:57 -04:00
committed by GitHub
parent aa225a4450
commit 78290301f4
6 changed files with 358 additions and 4 deletions
+67
View File
@@ -163,6 +163,14 @@
],
"type": "object"
},
"AlertRuleEditorSettings": {
"properties": {
"simplified_query_and_expressions_section": {
"type": "boolean"
}
},
"type": "object"
},
"AlertRuleExport": {
"properties": {
"annotations": {
@@ -286,6 +294,14 @@
},
"type": "object"
},
"AlertRuleMetadata": {
"properties": {
"editor_settings": {
"$ref": "#/definitions/AlertRuleEditorSettings"
}
},
"type": "object"
},
"AlertRuleNotificationSettings": {
"properties": {
"group_by": {
@@ -1573,6 +1589,9 @@
"is_paused": {
"type": "boolean"
},
"metadata": {
"$ref": "#/definitions/AlertRuleMetadata"
},
"namespace_uid": {
"type": "string"
},
@@ -1660,12 +1679,25 @@
},
"GettableRuleGroupConfig": {
"properties": {
"align_evaluation_time_on_interval": {
"type": "boolean"
},
"evaluation_delay": {
"type": "string"
},
"interval": {
"$ref": "#/definitions/Duration"
},
"limit": {
"format": "int64",
"type": "integer"
},
"name": {
"type": "string"
},
"query_offset": {
"type": "string"
},
"rules": {
"items": {
"$ref": "#/definitions/GettableExtendedRuleNode"
@@ -2786,6 +2818,9 @@
"is_paused": {
"type": "boolean"
},
"metadata": {
"$ref": "#/definitions/AlertRuleMetadata"
},
"no_data_state": {
"enum": [
"Alerting",
@@ -2824,17 +2859,36 @@
},
"PostableRuleGroupConfig": {
"properties": {
"align_evaluation_time_on_interval": {
"type": "boolean"
},
"evaluation_delay": {
"type": "string"
},
"interval": {
"$ref": "#/definitions/Duration"
},
"limit": {
"format": "int64",
"type": "integer"
},
"name": {
"type": "string"
},
"query_offset": {
"type": "string"
},
"rules": {
"items": {
"$ref": "#/definitions/PostableExtendedRuleNode"
},
"type": "array"
},
"source_tenants": {
"items": {
"type": "string"
},
"type": "array"
}
},
"type": "object"
@@ -3616,12 +3670,25 @@
},
"RuleGroupConfigResponse": {
"properties": {
"align_evaluation_time_on_interval": {
"type": "boolean"
},
"evaluation_delay": {
"type": "string"
},
"interval": {
"$ref": "#/definitions/Duration"
},
"limit": {
"format": "int64",
"type": "integer"
},
"name": {
"type": "string"
},
"query_offset": {
"type": "string"
},
"rules": {
"items": {
"$ref": "#/definitions/GettableExtendedRuleNode"