Skip to content

UI bug when editing Elasticsearch query alert rule "GROUPED OVER" a runtime_mapping field#223975

Merged
doakalexi merged 2 commits intoelastic:mainfrom
doakalexi:bug/edit-runtime-group-by
Jun 17, 2025
Merged

UI bug when editing Elasticsearch query alert rule "GROUPED OVER" a runtime_mapping field#223975
doakalexi merged 2 commits intoelastic:mainfrom
doakalexi:bug/edit-runtime-group-by

Conversation

@doakalexi
Copy link
Contributor

@doakalexi doakalexi commented Jun 13, 2025

Resolves #221447

Summary

This PR fixes a UI bug when editing an ES query rule that's grouping over a runtime field.

Checklist

Check the PR satisfies following conditions.

To verify

  1. Create a DSL ES Query rule and include a runtime field. Here is an example that I like to use
  "runtime_mappings": {
    "day_of_week": {
      "type": "keyword",
      "script": {
        "source": "emit(doc['@timestamp'].value.dayOfWeekEnum.getDisplayName(TextStyle.FULL, Locale.ENGLISH))"
      }
    }
  },

  1. Select that field to groupover and save your rule
  2. Edit your rule and click on GROUPED OVER, verify that there is no error and the runtime field is selected

@doakalexi doakalexi changed the title Fixing bug when editing rule grouping by a runtime field UI bug when editing Elasticsearch query alert rule "GROUPED OVER" a runtime_mapping field Jun 16, 2025
@doakalexi doakalexi added release_note:skip Skip the PR/issue when compiling release notes Team:ResponseOps Platform ResponseOps team (formerly the Cases and Alerting teams) t// v9.0.0 backport:version Backport to applied version labels v8.18.0 v9.1.0 v8.19.0 labels Jun 16, 2025
@doakalexi doakalexi requested review from umbopepato and ymao1 June 16, 2025 21:30
@doakalexi doakalexi marked this pull request as ready for review June 16, 2025 21:30
@doakalexi doakalexi requested a review from a team as a code owner June 16, 2025 21:30
@elasticmachine
Copy link
Contributor

Pinging @elastic/response-ops (Team:ResponseOps)

@elasticmachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
stackAlerts 65.3KB 65.4KB +69.0B

History

Copy link
Contributor

@ymao1 ymao1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Verified bug is fixed with this PR 🎉

setRuleProperty('params', currentRuleParams);
setXJson(esQuery ?? DEFAULT_VALUES.QUERY);
const query = esQuery ?? DEFAULT_VALUES.QUERY;
setXJson(query);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just curious, was it part of the fix to separate this into 2 lines?

Copy link
Contributor Author

@doakalexi doakalexi Jun 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no it's not necessary for the fix sorry! I just didnt want to repeat esQuery ?? DEFAULT_VALUES.QUERY in getRuntimeFields so I saved it in a variable. I can put it back tho!

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh I didn't see it was reused later. All good.

@doakalexi doakalexi merged commit 0a5df04 into elastic:main Jun 17, 2025
10 checks passed
@kibanamachine
Copy link
Contributor

Starting backport for target branches: 8.18, 8.19, 9.0

https://github.com/elastic/kibana/actions/runs/15715092479

kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Jun 17, 2025
…untime_mapping field (elastic#223975)

Resolves elastic#221447

## Summary

This PR fixes a UI bug when editing an ES query rule that's grouping
over a runtime field.

### Checklist

Check the PR satisfies following conditions.

- [ ] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

### To verify

1. Create a DSL ES Query rule and include a runtime field. Here is an
example that I like to use
```
  "runtime_mappings": {
    "day_of_week": {
      "type": "keyword",
      "script": {
        "source": "emit(doc['@timestamp'].value.dayOfWeekEnum.getDisplayName(TextStyle.FULL, Locale.ENGLISH))"
      }
    }
  },

```
2. Select that field to groupover and save your rule
3. Edit your rule and click on `GROUPED OVER`, verify that there is no
error and the runtime field is selected

(cherry picked from commit 0a5df04)
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Jun 17, 2025
…untime_mapping field (elastic#223975)

Resolves elastic#221447

## Summary

This PR fixes a UI bug when editing an ES query rule that's grouping
over a runtime field.

### Checklist

Check the PR satisfies following conditions.

- [ ] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

### To verify

1. Create a DSL ES Query rule and include a runtime field. Here is an
example that I like to use
```
  "runtime_mappings": {
    "day_of_week": {
      "type": "keyword",
      "script": {
        "source": "emit(doc['@timestamp'].value.dayOfWeekEnum.getDisplayName(TextStyle.FULL, Locale.ENGLISH))"
      }
    }
  },

```
2. Select that field to groupover and save your rule
3. Edit your rule and click on `GROUPED OVER`, verify that there is no
error and the runtime field is selected

(cherry picked from commit 0a5df04)
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Jun 17, 2025
…untime_mapping field (elastic#223975)

Resolves elastic#221447

## Summary

This PR fixes a UI bug when editing an ES query rule that's grouping
over a runtime field.

### Checklist

Check the PR satisfies following conditions.

- [ ] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

### To verify

1. Create a DSL ES Query rule and include a runtime field. Here is an
example that I like to use
```
  "runtime_mappings": {
    "day_of_week": {
      "type": "keyword",
      "script": {
        "source": "emit(doc['@timestamp'].value.dayOfWeekEnum.getDisplayName(TextStyle.FULL, Locale.ENGLISH))"
      }
    }
  },

```
2. Select that field to groupover and save your rule
3. Edit your rule and click on `GROUPED OVER`, verify that there is no
error and the runtime field is selected

(cherry picked from commit 0a5df04)
@kibanamachine
Copy link
Contributor

💚 All backports created successfully

Status Branch Result
8.18
8.19
9.0

Note: Successful backport PRs will be merged automatically after passing CI.

Questions ?

Please refer to the Backport tool documentation

@kibanamachine kibanamachine added the backport missing Added to PRs automatically when the are determined to be missing a backport. label Jun 19, 2025
@kibanamachine
Copy link
Contributor

Looks like this PR has backport PRs but they still haven't been merged. Please merge them ASAP to keep the branches relatively in sync.
cc: @doakalexi

doakalexi added a commit to doakalexi/kibana that referenced this pull request Jun 20, 2025
…untime_mapping field (elastic#223975)

Resolves elastic#221447

## Summary

This PR fixes a UI bug when editing an ES query rule that's grouping
over a runtime field.

### Checklist

Check the PR satisfies following conditions.

- [ ] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

### To verify

1. Create a DSL ES Query rule and include a runtime field. Here is an
example that I like to use
```
  "runtime_mappings": {
    "day_of_week": {
      "type": "keyword",
      "script": {
        "source": "emit(doc['@timestamp'].value.dayOfWeekEnum.getDisplayName(TextStyle.FULL, Locale.ENGLISH))"
      }
    }
  },

```
2. Select that field to groupover and save your rule
3. Edit your rule and click on `GROUPED OVER`, verify that there is no
error and the runtime field is selected

(cherry picked from commit 0a5df04)
@doakalexi
Copy link
Contributor Author

💚 All backports created successfully

Status Branch Result
9.0
8.19
8.18

Note: Successful backport PRs will be merged automatically after passing CI.

Questions ?

Please refer to the Backport tool documentation

doakalexi added a commit to doakalexi/kibana that referenced this pull request Jun 20, 2025
…untime_mapping field (elastic#223975)

Resolves elastic#221447

## Summary

This PR fixes a UI bug when editing an ES query rule that's grouping
over a runtime field.

### Checklist

Check the PR satisfies following conditions.

- [ ] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

### To verify

1. Create a DSL ES Query rule and include a runtime field. Here is an
example that I like to use
```
  "runtime_mappings": {
    "day_of_week": {
      "type": "keyword",
      "script": {
        "source": "emit(doc['@timestamp'].value.dayOfWeekEnum.getDisplayName(TextStyle.FULL, Locale.ENGLISH))"
      }
    }
  },

```
2. Select that field to groupover and save your rule
3. Edit your rule and click on `GROUPED OVER`, verify that there is no
error and the runtime field is selected

(cherry picked from commit 0a5df04)
doakalexi added a commit to doakalexi/kibana that referenced this pull request Jun 20, 2025
…untime_mapping field (elastic#223975)

Resolves elastic#221447

## Summary

This PR fixes a UI bug when editing an ES query rule that's grouping
over a runtime field.

### Checklist

Check the PR satisfies following conditions.

- [ ] [Unit or functional
tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)
were updated or added to match the most common scenarios

### To verify

1. Create a DSL ES Query rule and include a runtime field. Here is an
example that I like to use
```
  "runtime_mappings": {
    "day_of_week": {
      "type": "keyword",
      "script": {
        "source": "emit(doc['@timestamp'].value.dayOfWeekEnum.getDisplayName(TextStyle.FULL, Locale.ENGLISH))"
      }
    }
  },

```
2. Select that field to groupover and save your rule
3. Edit your rule and click on `GROUPED OVER`, verify that there is no
error and the runtime field is selected

(cherry picked from commit 0a5df04)
doakalexi added a commit that referenced this pull request Jun 20, 2025
…R" a runtime_mapping field (#223975) (#224718)

# Backport

This will backport the following commits from `main` to `9.0`:
- [UI bug when editing Elasticsearch query alert rule "GROUPED OVER" a
runtime_mapping field
(#223975)](#223975)

<!--- Backport version: 10.0.1 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Alexi
Doak","email":"109488926+doakalexi@users.noreply.github.com"},"sourceCommit":{"committedDate":"2025-06-17T18:19:28Z","message":"UI
bug when editing Elasticsearch query alert rule \"GROUPED OVER\" a
runtime_mapping field (#223975)\n\nResolves
https://github.com/elastic/kibana/issues/221447\n\n## Summary\n\nThis PR
fixes a UI bug when editing an ES query rule that's grouping\nover a
runtime field.\n\n\n### Checklist\n\nCheck the PR satisfies following
conditions. \n\n- [ ] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common scenarios\n\n\n### To
verify\n\n1. Create a DSL ES Query rule and include a runtime field.
Here is an\nexample that I like to use\n```\n \"runtime_mappings\": {\n
\"day_of_week\": {\n \"type\": \"keyword\",\n \"script\": {\n
\"source\":
\"emit(doc['@timestamp'].value.dayOfWeekEnum.getDisplayName(TextStyle.FULL,
Locale.ENGLISH))\"\n }\n }\n },\n\n```\n2. Select that field to
groupover and save your rule\n3. Edit your rule and click on `GROUPED
OVER`, verify that there is no\nerror and the runtime field is
selected","sha":"0a5df0462d75b23fc2088957eeca28d46c1ed8d8","branchLabelMapping":{"^v9.1.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","Team:ResponseOps","backport
missing","v9.0.0","backport:version","v8.18.0","v9.1.0","v8.19.0"],"title":"UI
bug when editing Elasticsearch query alert rule \"GROUPED OVER\" a
runtime_mapping
field","number":223975,"url":"https://github.com/elastic/kibana/pull/223975","mergeCommit":{"message":"UI
bug when editing Elasticsearch query alert rule \"GROUPED OVER\" a
runtime_mapping field (#223975)\n\nResolves
https://github.com/elastic/kibana/issues/221447\n\n## Summary\n\nThis PR
fixes a UI bug when editing an ES query rule that's grouping\nover a
runtime field.\n\n\n### Checklist\n\nCheck the PR satisfies following
conditions. \n\n- [ ] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common scenarios\n\n\n### To
verify\n\n1. Create a DSL ES Query rule and include a runtime field.
Here is an\nexample that I like to use\n```\n \"runtime_mappings\": {\n
\"day_of_week\": {\n \"type\": \"keyword\",\n \"script\": {\n
\"source\":
\"emit(doc['@timestamp'].value.dayOfWeekEnum.getDisplayName(TextStyle.FULL,
Locale.ENGLISH))\"\n }\n }\n },\n\n```\n2. Select that field to
groupover and save your rule\n3. Edit your rule and click on `GROUPED
OVER`, verify that there is no\nerror and the runtime field is
selected","sha":"0a5df0462d75b23fc2088957eeca28d46c1ed8d8"}},"sourceBranch":"main","suggestedTargetBranches":[],"targetPullRequestStates":[{"branch":"9.0","label":"v9.0.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/224320","number":224320,"state":"OPEN"},{"branch":"8.18","label":"v8.18.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/224318","number":224318,"state":"OPEN"},{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/223975","number":223975,"mergeCommit":{"message":"UI
bug when editing Elasticsearch query alert rule \"GROUPED OVER\" a
runtime_mapping field (#223975)\n\nResolves
https://github.com/elastic/kibana/issues/221447\n\n## Summary\n\nThis PR
fixes a UI bug when editing an ES query rule that's grouping\nover a
runtime field.\n\n\n### Checklist\n\nCheck the PR satisfies following
conditions. \n\n- [ ] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common scenarios\n\n\n### To
verify\n\n1. Create a DSL ES Query rule and include a runtime field.
Here is an\nexample that I like to use\n```\n \"runtime_mappings\": {\n
\"day_of_week\": {\n \"type\": \"keyword\",\n \"script\": {\n
\"source\":
\"emit(doc['@timestamp'].value.dayOfWeekEnum.getDisplayName(TextStyle.FULL,
Locale.ENGLISH))\"\n }\n }\n },\n\n```\n2. Select that field to
groupover and save your rule\n3. Edit your rule and click on `GROUPED
OVER`, verify that there is no\nerror and the runtime field is
selected","sha":"0a5df0462d75b23fc2088957eeca28d46c1ed8d8"}},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/224319","number":224319,"state":"OPEN"}]}]
BACKPORT-->
doakalexi added a commit that referenced this pull request Jun 20, 2025
…ER" a runtime_mapping field (#223975) (#224719)

# Backport

This will backport the following commits from `main` to `8.19`:
- [UI bug when editing Elasticsearch query alert rule "GROUPED OVER" a
runtime_mapping field
(#223975)](#223975)

<!--- Backport version: 10.0.1 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Alexi
Doak","email":"109488926+doakalexi@users.noreply.github.com"},"sourceCommit":{"committedDate":"2025-06-17T18:19:28Z","message":"UI
bug when editing Elasticsearch query alert rule \"GROUPED OVER\" a
runtime_mapping field (#223975)\n\nResolves
https://github.com/elastic/kibana/issues/221447\n\n## Summary\n\nThis PR
fixes a UI bug when editing an ES query rule that's grouping\nover a
runtime field.\n\n\n### Checklist\n\nCheck the PR satisfies following
conditions. \n\n- [ ] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common scenarios\n\n\n### To
verify\n\n1. Create a DSL ES Query rule and include a runtime field.
Here is an\nexample that I like to use\n```\n \"runtime_mappings\": {\n
\"day_of_week\": {\n \"type\": \"keyword\",\n \"script\": {\n
\"source\":
\"emit(doc['@timestamp'].value.dayOfWeekEnum.getDisplayName(TextStyle.FULL,
Locale.ENGLISH))\"\n }\n }\n },\n\n```\n2. Select that field to
groupover and save your rule\n3. Edit your rule and click on `GROUPED
OVER`, verify that there is no\nerror and the runtime field is
selected","sha":"0a5df0462d75b23fc2088957eeca28d46c1ed8d8","branchLabelMapping":{"^v9.1.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","Team:ResponseOps","backport
missing","v9.0.0","backport:version","v8.18.0","v9.1.0","v8.19.0"],"title":"UI
bug when editing Elasticsearch query alert rule \"GROUPED OVER\" a
runtime_mapping
field","number":223975,"url":"https://github.com/elastic/kibana/pull/223975","mergeCommit":{"message":"UI
bug when editing Elasticsearch query alert rule \"GROUPED OVER\" a
runtime_mapping field (#223975)\n\nResolves
https://github.com/elastic/kibana/issues/221447\n\n## Summary\n\nThis PR
fixes a UI bug when editing an ES query rule that's grouping\nover a
runtime field.\n\n\n### Checklist\n\nCheck the PR satisfies following
conditions. \n\n- [ ] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common scenarios\n\n\n### To
verify\n\n1. Create a DSL ES Query rule and include a runtime field.
Here is an\nexample that I like to use\n```\n \"runtime_mappings\": {\n
\"day_of_week\": {\n \"type\": \"keyword\",\n \"script\": {\n
\"source\":
\"emit(doc['@timestamp'].value.dayOfWeekEnum.getDisplayName(TextStyle.FULL,
Locale.ENGLISH))\"\n }\n }\n },\n\n```\n2. Select that field to
groupover and save your rule\n3. Edit your rule and click on `GROUPED
OVER`, verify that there is no\nerror and the runtime field is
selected","sha":"0a5df0462d75b23fc2088957eeca28d46c1ed8d8"}},"sourceBranch":"main","suggestedTargetBranches":[],"targetPullRequestStates":[{"branch":"9.0","label":"v9.0.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/224320","number":224320,"state":"OPEN"},{"branch":"8.18","label":"v8.18.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/224318","number":224318,"state":"OPEN"},{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/223975","number":223975,"mergeCommit":{"message":"UI
bug when editing Elasticsearch query alert rule \"GROUPED OVER\" a
runtime_mapping field (#223975)\n\nResolves
https://github.com/elastic/kibana/issues/221447\n\n## Summary\n\nThis PR
fixes a UI bug when editing an ES query rule that's grouping\nover a
runtime field.\n\n\n### Checklist\n\nCheck the PR satisfies following
conditions. \n\n- [ ] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common scenarios\n\n\n### To
verify\n\n1. Create a DSL ES Query rule and include a runtime field.
Here is an\nexample that I like to use\n```\n \"runtime_mappings\": {\n
\"day_of_week\": {\n \"type\": \"keyword\",\n \"script\": {\n
\"source\":
\"emit(doc['@timestamp'].value.dayOfWeekEnum.getDisplayName(TextStyle.FULL,
Locale.ENGLISH))\"\n }\n }\n },\n\n```\n2. Select that field to
groupover and save your rule\n3. Edit your rule and click on `GROUPED
OVER`, verify that there is no\nerror and the runtime field is
selected","sha":"0a5df0462d75b23fc2088957eeca28d46c1ed8d8"}},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/224319","number":224319,"state":"OPEN"}]}]
BACKPORT-->
doakalexi added a commit that referenced this pull request Jun 20, 2025
…ER" a runtime_mapping field (#223975) (#224720)

# Backport

This will backport the following commits from `main` to `8.18`:
- [UI bug when editing Elasticsearch query alert rule "GROUPED OVER" a
runtime_mapping field
(#223975)](#223975)

<!--- Backport version: 10.0.1 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sorenlouv/backport)

<!--BACKPORT [{"author":{"name":"Alexi
Doak","email":"109488926+doakalexi@users.noreply.github.com"},"sourceCommit":{"committedDate":"2025-06-17T18:19:28Z","message":"UI
bug when editing Elasticsearch query alert rule \"GROUPED OVER\" a
runtime_mapping field (#223975)\n\nResolves
https://github.com/elastic/kibana/issues/221447\n\n## Summary\n\nThis PR
fixes a UI bug when editing an ES query rule that's grouping\nover a
runtime field.\n\n\n### Checklist\n\nCheck the PR satisfies following
conditions. \n\n- [ ] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common scenarios\n\n\n### To
verify\n\n1. Create a DSL ES Query rule and include a runtime field.
Here is an\nexample that I like to use\n```\n \"runtime_mappings\": {\n
\"day_of_week\": {\n \"type\": \"keyword\",\n \"script\": {\n
\"source\":
\"emit(doc['@timestamp'].value.dayOfWeekEnum.getDisplayName(TextStyle.FULL,
Locale.ENGLISH))\"\n }\n }\n },\n\n```\n2. Select that field to
groupover and save your rule\n3. Edit your rule and click on `GROUPED
OVER`, verify that there is no\nerror and the runtime field is
selected","sha":"0a5df0462d75b23fc2088957eeca28d46c1ed8d8","branchLabelMapping":{"^v9.1.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","Team:ResponseOps","backport
missing","v9.0.0","backport:version","v8.18.0","v9.1.0","v8.19.0"],"title":"UI
bug when editing Elasticsearch query alert rule \"GROUPED OVER\" a
runtime_mapping
field","number":223975,"url":"https://github.com/elastic/kibana/pull/223975","mergeCommit":{"message":"UI
bug when editing Elasticsearch query alert rule \"GROUPED OVER\" a
runtime_mapping field (#223975)\n\nResolves
https://github.com/elastic/kibana/issues/221447\n\n## Summary\n\nThis PR
fixes a UI bug when editing an ES query rule that's grouping\nover a
runtime field.\n\n\n### Checklist\n\nCheck the PR satisfies following
conditions. \n\n- [ ] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common scenarios\n\n\n### To
verify\n\n1. Create a DSL ES Query rule and include a runtime field.
Here is an\nexample that I like to use\n```\n \"runtime_mappings\": {\n
\"day_of_week\": {\n \"type\": \"keyword\",\n \"script\": {\n
\"source\":
\"emit(doc['@timestamp'].value.dayOfWeekEnum.getDisplayName(TextStyle.FULL,
Locale.ENGLISH))\"\n }\n }\n },\n\n```\n2. Select that field to
groupover and save your rule\n3. Edit your rule and click on `GROUPED
OVER`, verify that there is no\nerror and the runtime field is
selected","sha":"0a5df0462d75b23fc2088957eeca28d46c1ed8d8"}},"sourceBranch":"main","suggestedTargetBranches":[],"targetPullRequestStates":[{"branch":"9.0","label":"v9.0.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/224320","number":224320,"state":"OPEN"},{"branch":"8.18","label":"v8.18.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/224318","number":224318,"state":"OPEN"},{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/223975","number":223975,"mergeCommit":{"message":"UI
bug when editing Elasticsearch query alert rule \"GROUPED OVER\" a
runtime_mapping field (#223975)\n\nResolves
https://github.com/elastic/kibana/issues/221447\n\n## Summary\n\nThis PR
fixes a UI bug when editing an ES query rule that's grouping\nover a
runtime field.\n\n\n### Checklist\n\nCheck the PR satisfies following
conditions. \n\n- [ ] [Unit or
functional\ntests](https://www.elastic.co/guide/en/kibana/master/development-tests.html)\nwere
updated or added to match the most common scenarios\n\n\n### To
verify\n\n1. Create a DSL ES Query rule and include a runtime field.
Here is an\nexample that I like to use\n```\n \"runtime_mappings\": {\n
\"day_of_week\": {\n \"type\": \"keyword\",\n \"script\": {\n
\"source\":
\"emit(doc['@timestamp'].value.dayOfWeekEnum.getDisplayName(TextStyle.FULL,
Locale.ENGLISH))\"\n }\n }\n },\n\n```\n2. Select that field to
groupover and save your rule\n3. Edit your rule and click on `GROUPED
OVER`, verify that there is no\nerror and the runtime field is
selected","sha":"0a5df0462d75b23fc2088957eeca28d46c1ed8d8"}},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"url":"https://github.com/elastic/kibana/pull/224319","number":224319,"state":"OPEN"}]}]
BACKPORT-->
@kibanamachine kibanamachine added v8.18.3 and removed backport missing Added to PRs automatically when the are determined to be missing a backport. labels Jun 20, 2025
@mistic mistic added v8.18.4 and removed v8.18.3 labels Jun 24, 2025
@mistic
Copy link
Contributor

mistic commented Jun 24, 2025

This PR didn't make it on time for the latest v8.18.3 and v9.0.3 BC. Updating the labels

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:version Backport to applied version labels release_note:skip Skip the PR/issue when compiling release notes Team:ResponseOps Platform ResponseOps team (formerly the Cases and Alerting teams) t// v8.18.0 v8.18.4 v8.19.0 v9.0.4 v9.1.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

UI bug when editing Elasticsearch query alert rule "GROUPED OVER" a runtime_mapping field

5 participants