Skip to content
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

[RAM][Security Solution][Alerts] moves legacy actions migration to rulesClient using hook in rules type definition #152362

Conversation

vitaliidm
Copy link
Contributor

@vitaliidm vitaliidm commented Feb 28, 2023

Summary

Checklist

Delete any items that are not applicable to this PR.

Risk Matrix

Delete this section if it is not applicable to this PR.

Before closing this PR, invite QA, stakeholders, and other developers to identify risks that should be tested prior to the change/feature release.

When forming the risk matrix, consider some of the following examples and how they may potentially impact the change:

Risk Probability Severity Mitigation/Notes
Multiple Spaces—unexpected behavior in non-default Kibana Space. Low High Integration tests will verify that all features are still supported in non-default Kibana Space and when user switches between spaces.
Multiple nodes—Elasticsearch polling might have race conditions when multiple Kibana nodes are polling for the same tasks. High Low Tasks are idempotent, so executing them multiple times will not result in logical error, but will degrade performance. To test for this case we add plenty of unit tests around this logic and document manual testing procedure.
Code should gracefully handle cases when feature X or plugin Y are disabled. Medium High Unit tests will verify that any feature flag or plugin combination still results in our service operational.
See more potential risk examples

For maintainers

@vitaliidm vitaliidm self-assigned this Feb 28, 2023
kibanamachine and others added 6 commits February 28, 2023 16:27
…ithub.com/vitaliidm/kibana into alerts/legacy-actions-migration-to-alerting

# Conflicts:
#	x-pack/plugins/security_solution/server/lib/detection_engine/rule_actions_legacy/logic/rule_actions/legacy_rules_client_migration_hook.ts
@elastic elastic deleted a comment from kibana-ci Feb 28, 2023
@vitaliidm vitaliidm added refactoring release_note:skip Skip the PR/issue when compiling release notes backport:skip This commit does not require backporting Team: SecuritySolution Security Solutions Team working on SIEM, Endpoint, Timeline, Resolver, etc. Team:Detection Alerts Security Detection Alerts Area Team v8.8.0 labels Mar 8, 2023
@vitaliidm
Copy link
Contributor Author

@elasticmachine merge upstream

@kibanamachine
Copy link
Contributor

merge conflict between base and head

# Conflicts:
#	x-pack/plugins/alerting/server/index.ts
#	x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/logic/rule_objects/update_prebuilt_rules.test.ts
#	x-pack/plugins/security_solution/server/lib/detection_engine/prebuilt_rules/logic/rule_objects/update_prebuilt_rules.ts
@vitaliidm vitaliidm changed the title [RAM][Security Solution][Alerts] moves legacy actions migration to rulesClient [RAM][Security Solution][Alerts] moves legacy actions migration to rulesClient using hook in rules type definition Mar 10, 2023
@vitaliidm
Copy link
Contributor Author

vitaliidm commented Mar 10, 2023

Leaving this PR for historical and tracking purposes as POC of moving legacy migration to rulesClient through hook in rule type definition.

Further work, will be done in #153101, which is based on this, but migration will be implemented directly in RulesClient instead of passing as hook

@vitaliidm vitaliidm closed this Mar 10, 2023
@kibana-ci
Copy link
Collaborator

kibana-ci commented Mar 10, 2023

💔 Build Failed

Failed CI Steps

Test Failures

  • [job] [logs] Security Solution Tests #4 / Exceptions flyout "after each" hook for "Warns users about mapping conflicts on problematic field selection"
  • [job] [logs] Jest Tests #8 / rules_client_conflict_retries 1 retry works for method update
  • [job] [logs] Jest Tests #8 / rules_client_conflict_retries 3 retries fails with conflict error update

Metrics [docs]

Public APIs missing comments

Total count of every public API that lacks a comment. Target amount is 0. Run node scripts/build_api_docs --plugin [yourplugin] --stats comments for more detailed information.

id before after diff
alerting 515 523 +8
Unknown metric groups

API count

id before after diff
alerting 531 539 +8

ESLint disabled line counts

id before after diff
securitySolution 432 416 -16

Total ESLint disabled count

id before after diff
securitySolution 509 493 -16

History

To update your PR or re-run it, just comment with:
@elasticmachine merge upstream

cc @vitaliidm

@vitaliidm vitaliidm removed the v8.8.0 label Mar 29, 2023
@vitaliidm vitaliidm deleted the alerts/legacy-actions-migration-to-alerting branch March 4, 2024 17:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:skip This commit does not require backporting refactoring release_note:skip Skip the PR/issue when compiling release notes Team:Detection Alerts Security Detection Alerts Area Team Team: SecuritySolution Security Solutions Team working on SIEM, Endpoint, Timeline, Resolver, etc.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants