[ML] Fix schema definition for the module endpoint #191633
Merged
darnautov merged 2 commits intoelastic:mainfrom Aug 30, 2024
Merged
[ML] Fix schema definition for the module endpoint #191633darnautov merged 2 commits intoelastic:mainfrom
darnautov merged 2 commits intoelastic:mainfrom
Conversation
Contributor
|
Pinging @elastic/ml-ui (:ml) |
| query: schema.maybe(schema.any()), | ||
| jobs: schema.arrayOf(schema.any()), | ||
| datafeeds: schema.arrayOf(schema.any()), | ||
| kibana: schema.any(), |
Contributor
There was a problem hiding this comment.
I believe kibana can also be missing so should be wrapped in schema.maybe(... - this is also required for the endpoint to work when not passing args and just getting the modules list.
9 tasks
maximpn
approved these changes
Aug 28, 2024
Contributor
maximpn
left a comment
There was a problem hiding this comment.
@darnautov Thanks for fixing the issue 👍
I tested Rule Management table and the issue introduced by #190840 is fixed.
💛 Build succeeded, but was flaky
Failed CI StepsMetrics [docs]
History
To update your PR or re-run it, just comment with: cc @darnautov |
alvarezmelissa87
approved these changes
Aug 29, 2024
alvarezmelissa87
added a commit
that referenced
this pull request
Sep 12, 2024
…r Supplied configurations (ML Modules) (#191564) ## Summary This PR adds a page in the UI for 'Supplied configurations' Dependent on this fix to the endpoint schema going in first: #191633 NOTE: This item will be added to the side-nav of oblt serverless once this update is in: #190458 Adds dedicated UI page for preconfigured job packages - subitem of the Anomaly Detection navigation: <img width="1721" alt="image" src="https://github.com/user-attachments/assets/194bbf44-aa7c-4afa-94e3-587fb9e5f601"> When they can't be run in the ML UI: <img width="1467" alt="image" src="https://github.com/user-attachments/assets/487463e8-7520-48de-8806-1d45a82e452e"> When selected - flyout opens to reveal package assets: <img width="1098" alt="image" src="https://github.com/user-attachments/assets/a648a6d8-df79-4bb3-a797-61f02e246c9b"> Clicking the `Run data recognizer` button shows matching data views (if any) with link to job creation: <img width="1099" alt="image" src="https://github.com/user-attachments/assets/05e9f7f7-e41f-486d-ba41-84cacf534cd0"> Empty table when no matching dataviews are found: <img width="999" alt="image" src="https://github.com/user-attachments/assets/d8bbf3be-7035-4e2f-956e-83dfbc26b247"> Jobs tab of flyout: <img width="1102" alt="image" src="https://github.com/user-attachments/assets/e94efb2e-1f21-4883-aa2b-2c42db5be970"> kibana tab of flyout: <img width="1100" alt="image" src="https://github.com/user-attachments/assets/0021a527-8d9d-4e06-9fae-d832015f7f7d"> ### Checklist Delete any items that are not applicable to this PR. - [ ] 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/packages/kbn-i18n/README.md) - [ ] [Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html) was added for features that require explanation or tutorials - [ ] [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 - [ ] Any UI touched in this PR is usable by keyboard only (learn more about [keyboard accessibility](https://webaim.org/techniques/keyboard/)) - [ ] Any UI touched in this PR does not create any new axe failures (run axe in browser: [FF](https://addons.mozilla.org/en-US/firefox/addon/axe-devtools/), [Chrome](https://chrome.google.com/webstore/detail/axe-web-accessibility-tes/lhdoppojpmngadmnindnejefpokejbdd?hl=en-US)) - [ ] If a plugin configuration key changed, check if it needs to be allowlisted in the cloud and added to the [docker list](https://github.com/elastic/kibana/blob/main/src/dev/build/tasks/os_packages/docker_generator/resources/base/bin/kibana-docker) - [ ] This renders correctly on smaller devices using a responsive layout. (You can test this [in your browser](https://www.browserstack.com/guide/responsive-testing-on-local-server)) - [ ] This was checked for [cross-browser compatibility](https://www.elastic.co/support/matrix#matrix_browsers) --------- Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes an issue introduced in #190840 where the module endpoint had a wrong type definition for response validation, causing the Rules page in Security plugin to crash.