-
Notifications
You must be signed in to change notification settings - Fork 8.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[8.12] [Response Ops][Alerting] Adding evaluation threshold to alert …
…payload for ES query rule (#171571) (#172814) # Backport This will backport the following commits from `main` to `8.12`: - [[Response Ops][Alerting] Adding evaluation threshold to alert payload for ES query rule (#171571)](#171571) <!--- Backport version: 8.9.7 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Ying Mao","email":"[email protected]"},"sourceCommit":{"committedDate":"2023-12-07T13:20:34Z","message":"[Response Ops][Alerting] Adding evaluation threshold to alert payload for ES query rule (#171571)\n\nResolves https://github.com/elastic/kibana/issues/166986\r\n\r\n## Summary\r\n\r\nAdding `kibana.alert.evalution.threshold` to the alert payload for the\r\nES query rule. This is the field that's shown in the alert details view\r\nin Observability. To show this, we add `ALERT_EVALUATION_CONDITIONS` to\r\nthe stack alerts mapping, using the same mapping type as the\r\nobservability rule types. This is typed as a `scaled_float` which is\r\nexpecting a single value, so the threshold is set in the alert payload\r\nonly when the threshold is a single value. I will open a followup issue\r\nfor handling multi-valued thresholds.\r\nhttps://github.com//issues/172714\r\n\r\n<img width=\"1064\" alt=\"Screenshot 2023-11-20 at 1 10 05 PM\"\r\nsrc=\"https://github.com/elastic/kibana/assets/13104637/e265a9e8-4bbf-4d3e-a6bc-e69b774c7574\">\r\n\r\n\r\n## To Verify\r\n\r\nCreate an ES query rule with a single threshold that triggers an alert\r\nand give it a Metrics or Logs visibility. Let it run and then look at\r\nthe alert details for the alert from the Observability alert table. The\r\n`Expected Value` row should be populated.","sha":"ec81569930bb91a55fec1ee8925826d804348361","branchLabelMapping":{"^v8.13.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","Feature:Alerting","Team:ResponseOps","v8.12.0","Team:obs-ux-management","v8.13.0"],"number":171571,"url":"https://github.com/elastic/kibana/pull/171571","mergeCommit":{"message":"[Response Ops][Alerting] Adding evaluation threshold to alert payload for ES query rule (#171571)\n\nResolves https://github.com/elastic/kibana/issues/166986\r\n\r\n## Summary\r\n\r\nAdding `kibana.alert.evalution.threshold` to the alert payload for the\r\nES query rule. This is the field that's shown in the alert details view\r\nin Observability. To show this, we add `ALERT_EVALUATION_CONDITIONS` to\r\nthe stack alerts mapping, using the same mapping type as the\r\nobservability rule types. This is typed as a `scaled_float` which is\r\nexpecting a single value, so the threshold is set in the alert payload\r\nonly when the threshold is a single value. I will open a followup issue\r\nfor handling multi-valued thresholds.\r\nhttps://github.com//issues/172714\r\n\r\n<img width=\"1064\" alt=\"Screenshot 2023-11-20 at 1 10 05 PM\"\r\nsrc=\"https://github.com/elastic/kibana/assets/13104637/e265a9e8-4bbf-4d3e-a6bc-e69b774c7574\">\r\n\r\n\r\n## To Verify\r\n\r\nCreate an ES query rule with a single threshold that triggers an alert\r\nand give it a Metrics or Logs visibility. Let it run and then look at\r\nthe alert details for the alert from the Observability alert table. The\r\n`Expected Value` row should be populated.","sha":"ec81569930bb91a55fec1ee8925826d804348361"}},"sourceBranch":"main","suggestedTargetBranches":["8.12"],"targetPullRequestStates":[{"branch":"8.12","label":"v8.12.0","labelRegex":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v8.13.0","labelRegex":"^v8.13.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/171571","number":171571,"mergeCommit":{"message":"[Response Ops][Alerting] Adding evaluation threshold to alert payload for ES query rule (#171571)\n\nResolves https://github.com/elastic/kibana/issues/166986\r\n\r\n## Summary\r\n\r\nAdding `kibana.alert.evalution.threshold` to the alert payload for the\r\nES query rule. This is the field that's shown in the alert details view\r\nin Observability. To show this, we add `ALERT_EVALUATION_CONDITIONS` to\r\nthe stack alerts mapping, using the same mapping type as the\r\nobservability rule types. This is typed as a `scaled_float` which is\r\nexpecting a single value, so the threshold is set in the alert payload\r\nonly when the threshold is a single value. I will open a followup issue\r\nfor handling multi-valued thresholds.\r\nhttps://github.com//issues/172714\r\n\r\n<img width=\"1064\" alt=\"Screenshot 2023-11-20 at 1 10 05 PM\"\r\nsrc=\"https://github.com/elastic/kibana/assets/13104637/e265a9e8-4bbf-4d3e-a6bc-e69b774c7574\">\r\n\r\n\r\n## To Verify\r\n\r\nCreate an ES query rule with a single threshold that triggers an alert\r\nand give it a Metrics or Logs visibility. Let it run and then look at\r\nthe alert details for the alert from the Observability alert table. The\r\n`Expected Value` row should be populated.","sha":"ec81569930bb91a55fec1ee8925826d804348361"}}]}] BACKPORT--> Co-authored-by: Ying Mao <[email protected]>
- Loading branch information
1 parent
33884c2
commit 857b1ad
Showing
15 changed files
with
120 additions
and
12 deletions.
There are no files selected for viewing
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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