Conversation
Add a ruleset exist check endpoint. Add a utility function to check common permissions in routes. Add a new hook for query rule check. Add new route for create mode in Ruleset Detail page. Modify the Query Rule creation modal to give navigation option to the user when ruleset already exists. Add tests for hook and utility function.
3308f12 to
4a61c42
Compare
|
Cloud deployment initiated, see credentials at: https://buildkite.com/elastic/kibana-deploy-cloud-from-pr/builds/243 |
Fixes various bugs.
4a61c42 to
c7031bd
Compare
|
@elasticmachine merge upstream |
Samiul-TheSoccerFan
left a comment
There was a problem hiding this comment.
Mostly look good, left some small comments. This is a large PR to review at once. I will do another round of review tomorrow.
...ic/components/query_ruleset_detail/query_rule_flyout/document_selector/document_selector.tsx
Show resolved
Hide resolved
sphilipse
left a comment
There was a problem hiding this comment.
two nitpicks but looks good overall
| <EuiText size="s"> | ||
| <EuiBadge>{criteria.metadata}</EuiBadge> | ||
| <EuiTextColor color={euiTheme.colors.textPrimary}>{criteria.type}</EuiTextColor> | ||
| {criteria.metadata && ( |
There was a problem hiding this comment.
this should be Boolean(criteria.metadata) or it'll show the metadata inline with eh...more metadata
| response.forbidden({ | ||
| body: i18n.translate('xpack.search.queryRules.api.routes.permissionError', { | ||
| defaultMessage: | ||
| "Your user doesn't have manage_search_query_rules privilegesUser does not have the required privileges to access this resource", |
There was a problem hiding this comment.
nitpick: this error message should probably lose everything from 'User' onwards
d251120 to
de456f1
Compare
💛 Build succeeded, but was flaky
Failed CI StepsTest Failures
Metrics [docs]Module Count
Async chunks
Page load bundle
History
|
Samiul-TheSoccerFan
left a comment
There was a problem hiding this comment.
LGTM, thank you for the explanations.
|
Starting backport for target branches: 8.19 https://github.com/elastic/kibana/actions/runs/15736934691 |
💔 All backports failed
Manual backportTo create the backport manually run: Questions ?Please refer to the Backport tool documentation |
| }); | ||
|
|
||
| return ( | ||
| <EuiPanel hasShadow={false} hasBorder={false} paddingSize="l"> |
| </> | ||
| )} | ||
| {criteria.type === 'always' ? ( | ||
| <EuiBadge> {criteria.type}</EuiBadge> |
There was a problem hiding this comment.
Is the extra space at the beginning intentional here? What about this one not having a after the badge like the other cases here?
|
Starting backport for target branches: 8.19 https://github.com/elastic/kibana/actions/runs/15741516701 |
## Summary Updates create flow and fixes some bugs. https://github.com/user-attachments/assets/b3525b50-df3f-42b5-9ede-13df53bd7bfb ### Checklist Check the PR satisfies following conditions. Reviewers should verify this PR satisfies this list as well. - [x] Any text added follows [EUI's writing guidelines](https://elastic.github.io/eui/#/guidelines/writing), uses sentence case text and includes [i18n support](https://github.com/elastic/kibana/blob/main/src/platform/packages/shared/kbn-i18n/README.md) - [x] [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 - [ ] [Flaky Test Runner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was used on any tests changed - [x] The PR description includes the appropriate Release Notes section, and the correct `release_note:*` label is applied per the [guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process) --------- Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com> (cherry picked from commit 32e3374)
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
# Backport This will backport the following commits from `main` to `8.19`: - [Query rules create mode (#223613)](#223613) <!--- Backport version: 9.6.6 --> ### Questions ? Please refer to the [Backport tool documentation](https://github.com/sorenlouv/backport) <!--BACKPORT [{"author":{"name":"Efe Gürkan YALAMAN","email":"efeguerkan.yalaman@elastic.co"},"sourceCommit":{"committedDate":"2025-06-18T15:21:32Z","message":"Query rules create mode (#223613)\n\n## Summary\n\nUpdates create flow and fixes some bugs.\n\n\nhttps://github.com/user-attachments/assets/b3525b50-df3f-42b5-9ede-13df53bd7bfb\n\n\n### Checklist\n\nCheck the PR satisfies following conditions. \n\nReviewers should verify this PR satisfies this list as well.\n\n- [x] Any text added follows [EUI's writing\nguidelines](https://elastic.github.io/eui/#/guidelines/writing), uses\nsentence case text and includes [i18n\nsupport](https://github.com/elastic/kibana/blob/main/src/platform/packages/shared/kbn-i18n/README.md)\n- [x] [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- [ ] [Flaky Test\nRunner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was\nused on any tests changed\n- [x] The PR description includes the appropriate Release Notes section,\nand the correct `release_note:*` label is applied per the\n[guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)\n\n---------\n\nCo-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>","sha":"32e337401350aa1c34a30ceacc92b642d64312dc","branchLabelMapping":{"^v9.1.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","ci:cloud-deploy","backport:version","v9.1.0","v8.19.0"],"title":"Query rules create mode","number":223613,"url":"https://github.com/elastic/kibana/pull/223613","mergeCommit":{"message":"Query rules create mode (#223613)\n\n## Summary\n\nUpdates create flow and fixes some bugs.\n\n\nhttps://github.com/user-attachments/assets/b3525b50-df3f-42b5-9ede-13df53bd7bfb\n\n\n### Checklist\n\nCheck the PR satisfies following conditions. \n\nReviewers should verify this PR satisfies this list as well.\n\n- [x] Any text added follows [EUI's writing\nguidelines](https://elastic.github.io/eui/#/guidelines/writing), uses\nsentence case text and includes [i18n\nsupport](https://github.com/elastic/kibana/blob/main/src/platform/packages/shared/kbn-i18n/README.md)\n- [x] [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- [ ] [Flaky Test\nRunner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was\nused on any tests changed\n- [x] The PR description includes the appropriate Release Notes section,\nand the correct `release_note:*` label is applied per the\n[guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)\n\n---------\n\nCo-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>","sha":"32e337401350aa1c34a30ceacc92b642d64312dc"}},"sourceBranch":"main","suggestedTargetBranches":["8.19"],"targetPullRequestStates":[{"branch":"main","label":"v9.1.0","branchLabelMappingKey":"^v9.1.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/223613","number":223613,"mergeCommit":{"message":"Query rules create mode (#223613)\n\n## Summary\n\nUpdates create flow and fixes some bugs.\n\n\nhttps://github.com/user-attachments/assets/b3525b50-df3f-42b5-9ede-13df53bd7bfb\n\n\n### Checklist\n\nCheck the PR satisfies following conditions. \n\nReviewers should verify this PR satisfies this list as well.\n\n- [x] Any text added follows [EUI's writing\nguidelines](https://elastic.github.io/eui/#/guidelines/writing), uses\nsentence case text and includes [i18n\nsupport](https://github.com/elastic/kibana/blob/main/src/platform/packages/shared/kbn-i18n/README.md)\n- [x] [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- [ ] [Flaky Test\nRunner](https://ci-stats.kibana.dev/trigger_flaky_test_runner/1) was\nused on any tests changed\n- [x] The PR description includes the appropriate Release Notes section,\nand the correct `release_note:*` label is applied per the\n[guidelines](https://www.elastic.co/guide/en/kibana/master/contributing.html#kibana-release-notes-process)\n\n---------\n\nCo-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>","sha":"32e337401350aa1c34a30ceacc92b642d64312dc"}},{"branch":"8.19","label":"v8.19.0","branchLabelMappingKey":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}] BACKPORT--> --------- Co-authored-by: Efe Gürkan YALAMAN <efeguerkan.yalaman@elastic.co> Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Summary
Updates create flow and fixes some bugs.
Screen.Recording.2025-06-16.at.22.44.46.mov
Checklist
Check the PR satisfies following conditions.
Reviewers should verify this PR satisfies this list as well.
release_note:*label is applied per the guidelines