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.
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Security Solution] [Platform] Migrate legacy actions whenever user interacts with the rule #115101
[Security Solution] [Platform] Migrate legacy actions whenever user interacts with the rule #115101
Changes from 11 commits
a88290b
cea2025
1ffd393
d3be062
d77f889
d536121
d3cd83b
cc67c59
2f74c4e
6498ff3
4c454c0
5059c56
9feda3a
c7cab46
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do we have this extra error throw here now? I wouldn't want to add another layer of validation. We are already validating the input arguments and then the response on the way out. We typically just validate on the API boundaries to ensure that the 3rd party services and user input work as we expect.
Within the boundaries we usually trust we are writing code well enough and straight forward enough. If this begins causing errors at this point I would want to fix the user input at the REST API boundary or the response boundary rather than fix issues here or worry about this part.
Otherwise future maintainers might have to maintain multiple spots of validation or change error codes in multiple spots, etc...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I actually saw this was missing here. This same piece is in the patch rules function
kibana/x-pack/plugins/security_solution/server/lib/detection_engine/rules/patch_rules.ts
Lines 204 to 207 in 512d594
And I figured it would be good to add it here to keep it consistent.