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][Actions] Fixing bug where context variables are…
… not passed in when alerts as data doc is available in action params (#175682) (#175737) # Backport This will backport the following commits from `main` to `8.12`: - [[Response Ops][Actions] Fixing bug where context variables are not passed in when alerts as data doc is available in action params (#175682)](#175682) <!--- Backport version: 9.4.3 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sqren/backport) <!--BACKPORT [{"author":{"name":"Ying Mao","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-01-26T21:36:35Z","message":"[Response Ops][Actions] Fixing bug where context variables are not passed in when alerts as data doc is available in action params (#175682)\n\nResolves https://github.com/elastic/kibana/issues/175624\r\n\r\n## Summary\r\n\r\nFixes a bug where context and state variables were not passed to the\r\naction params for interpolation if the alert-as-data document is\r\navailable.\r\n\r\n## To Verify\r\n* Create a rule and add an action that fires `For each alert - on check\r\nintervals`\r\n* Add a condition to the action, either a KQL query or a time range\r\n* Make sure the action message references some context variables\r\n(default ES query or Index Threshold rule messages should include\r\ncontext variables)\r\n* Save the rule and make sure the action fired correctly includes the\r\nreferenced context variables.\r\n\r\nCo-authored-by: Kibana Machine <[email protected]>","sha":"8a6ee8a4c0df7f687c57748c1e9f1155167b00aa","branchLabelMapping":{"^v8.13.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["bug","release_note:fix","Feature:Actions","Team:ResponseOps","v8.12.1","v8.13.0"],"title":"[Response Ops][Actions] Fixing bug where context variables are not passed in when alerts as data doc is available in action params","number":175682,"url":"https://github.com/elastic/kibana/pull/175682","mergeCommit":{"message":"[Response Ops][Actions] Fixing bug where context variables are not passed in when alerts as data doc is available in action params (#175682)\n\nResolves https://github.com/elastic/kibana/issues/175624\r\n\r\n## Summary\r\n\r\nFixes a bug where context and state variables were not passed to the\r\naction params for interpolation if the alert-as-data document is\r\navailable.\r\n\r\n## To Verify\r\n* Create a rule and add an action that fires `For each alert - on check\r\nintervals`\r\n* Add a condition to the action, either a KQL query or a time range\r\n* Make sure the action message references some context variables\r\n(default ES query or Index Threshold rule messages should include\r\ncontext variables)\r\n* Save the rule and make sure the action fired correctly includes the\r\nreferenced context variables.\r\n\r\nCo-authored-by: Kibana Machine <[email protected]>","sha":"8a6ee8a4c0df7f687c57748c1e9f1155167b00aa"}},"sourceBranch":"main","suggestedTargetBranches":["8.12"],"targetPullRequestStates":[{"branch":"8.12","label":"v8.12.1","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v8.13.0","branchLabelMappingKey":"^v8.13.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/175682","number":175682,"mergeCommit":{"message":"[Response Ops][Actions] Fixing bug where context variables are not passed in when alerts as data doc is available in action params (#175682)\n\nResolves https://github.com/elastic/kibana/issues/175624\r\n\r\n## Summary\r\n\r\nFixes a bug where context and state variables were not passed to the\r\naction params for interpolation if the alert-as-data document is\r\navailable.\r\n\r\n## To Verify\r\n* Create a rule and add an action that fires `For each alert - on check\r\nintervals`\r\n* Add a condition to the action, either a KQL query or a time range\r\n* Make sure the action message references some context variables\r\n(default ES query or Index Threshold rule messages should include\r\ncontext variables)\r\n* Save the rule and make sure the action fired correctly includes the\r\nreferenced context variables.\r\n\r\nCo-authored-by: Kibana Machine <[email protected]>","sha":"8a6ee8a4c0df7f687c57748c1e9f1155167b00aa"}}]}] BACKPORT--> Co-authored-by: Ying Mao <[email protected]>
- Loading branch information