[SIEM][Detection Engine] Fixes import bug with non existent signals index#65595
[SIEM][Detection Engine] Fixes import bug with non existent signals index#65595FrankHassanabad merged 2 commits intoelastic:masterfrom
Conversation
…ill creates the rules and activates them
| if (parsedRule instanceof Error) { | ||
| // If the JSON object had a validation or parse error then we return | ||
| // early with the error and an (unknown) for the ruleId | ||
| const importsWorkerPromise = new Promise<ImportRuleResponse>(async resolve => { |
There was a problem hiding this comment.
NOTE: formatting is all messed up because I removed the dead variable reject
| message: `To create a rule, the index must exist first. Index ${signalsIndex} does not exist`, | ||
| }) | ||
| ); | ||
| return null; |
There was a problem hiding this comment.
NOTE: Ignore what the diff says, this return null is what I added and only what I added.
There was a problem hiding this comment.
FYI You can always add ?w=1 to diff URIs, or select "Hide whitespaces changes" from the cog dropdown on the diff view.
There was a problem hiding this comment.
Ah of course! I used to do that before. Totally forgot about that feature. Thank you!
|
Pinging @elastic/siem (Team:SIEM) |
x-pack/plugins/siem/server/lib/detection_engine/routes/rules/import_rules_route.ts
Outdated
Show resolved
Hide resolved
dhurley14
left a comment
There was a problem hiding this comment.
LGTM - I think moving the index check above the while loop would be a minor improvement but not necessary. Thanks for the 🚫🐛
💚 Build SucceededHistory
To update your PR or re-run it, just comment with: |
…ndex (elastic#65595) See: elastic#65565 * Fixes it to where if there is an import without an index then the rule is not created ### Checklist - [x] [Unit or functional tests](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#cross-browser-compatibility) were updated or added to match the most common scenarios
* master: [ML] Transforms: Fix API error message display for edit flyout. (elastic#65494) [SIEM][Detection Engine] Fixes import bug with non existent signals index (elastic#65595) [Lens] Use rules of hooks with linting (elastic#65593) [ML] Migrate server side Mocha tests to Jest. (elastic#65651) Fixes the client to setup SSL with the CA certificates for testing (elastic#65598) reduce uptime plugin initial bundle size (elastic#65257) [ML] Consolidating shared types and util functions (elastic#65247) [Drilldowns] Preserve state when selecting different action factory (elastic#65074) Migrate test plugins ⇒ NP (kbn_tp_embeddable_explorer) (elastic#64756) Move remaining home assets to the new platform (elastic#65053) Change the copy and the id from blacklist to block list for consistency (elastic#65419) [ML] Hide selector helper in Anomaly Explorer swimlane (elastic#65522) [ML] Fix the limit control on the Anomaly explorer page (elastic#65459) [Mappings editor] Add component integration tests (elastic#63853) [Logs + Metrics UI] Prevent component errors from breaking the whole UI (elastic#65456) [Logs UI] Disable search bar when live stream is on. (elastic#65491)
…ponents * alerting/lazy-load-actions: align and style loading indicator [ML] Transforms: Fix API error message display for edit flyout. (elastic#65494) [SIEM][Detection Engine] Fixes import bug with non existent signals index (elastic#65595) [Lens] Use rules of hooks with linting (elastic#65593) [ML] Migrate server side Mocha tests to Jest. (elastic#65651) Fixes the client to setup SSL with the CA certificates for testing (elastic#65598) reduce uptime plugin initial bundle size (elastic#65257) [ML] Consolidating shared types and util functions (elastic#65247) [Drilldowns] Preserve state when selecting different action factory (elastic#65074) Migrate test plugins ⇒ NP (kbn_tp_embeddable_explorer) (elastic#64756) Move remaining home assets to the new platform (elastic#65053) Change the copy and the id from blacklist to block list for consistency (elastic#65419) [ML] Hide selector helper in Anomaly Explorer swimlane (elastic#65522) [ML] Fix the limit control on the Anomaly explorer page (elastic#65459) [Mappings editor] Add component integration tests (elastic#63853) [Logs + Metrics UI] Prevent component errors from breaking the whole UI (elastic#65456) [Logs UI] Disable search bar when live stream is on. (elastic#65491)
…ndex (#65595) (#65690) See: #65565 * Fixes it to where if there is an import without an index then the rule is not created ### Checklist - [x] [Unit or functional tests](https://github.com/elastic/kibana/blob/master/CONTRIBUTING.md#cross-browser-compatibility) were updated or added to match the most common scenarios
|
Pinging @elastic/security-solution (Team: SecuritySolution) |
See: #65565
Checklist