Skip to content

[Security Solution] Large number of related integrations can impact performance on rule creation/edit form #183607

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

Closed
Tracked by #214766 ...
vitaliidm opened this issue May 16, 2024 · 6 comments · Fixed by #217254
Assignees
Labels
9.1 candidate bug Fixes for quality problems that affect the customer experience Feature:Rule Creation Security Solution Detection Rule Creation workflow Feature:Rule Edit Security Solution Detection Rule Editing workflow impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. performance Team:Detection Engine Security Solution Detection Engine Area Team:Detection Rule Management Security Detection Rule Management Team Team:Detections and Resp Security Detection Response Team Team: SecuritySolution Security Solutions Team working on SIEM, Endpoint, Timeline, Resolver, etc.

Comments

@vitaliidm
Copy link
Contributor

vitaliidm commented May 16, 2024

Summary

Describe the bug:
Large number of related integrations can cause significant performance impact on rule creation/edit form.

Steps to reproduce:

  1. Go to rule edit/create form
  2. Add multiple related integrations
  3. Type query in query bar. There is a noticeable delay in response on browser page
  4. Observe in profiler, related integrations could take up to up to 10ms to re-render on each symbol typed.
    Potentially, even longer, if more added.

Current behavior:
Each added item to related integrations contribute to the total time of form re-rendering.
Component re-renders on any change in form. So, even typing query, that does not effect state of related integrations, causes this component to re-render.
Each added item, adds approx. 1ms in rendering time. For 8 items it takes 8ms, out of 30ms of total form re-render time.

Expected behavior:
Component should not re-render when thee are no changes in form that affect it.
Similar issue was discovered for required fields and handled in relevant PR

Screenshots (if relevant):

Screenshot 2024-05-16 at 10 19 30
@vitaliidm vitaliidm added bug Fixes for quality problems that affect the customer experience performance triage_needed Team: SecuritySolution Security Solutions Team working on SIEM, Endpoint, Timeline, Resolver, etc. Team:Detection Engine Security Solution Detection Engine Area labels May 16, 2024
@elasticmachine
Copy link
Contributor

Pinging @elastic/security-solution (Team: SecuritySolution)

@elasticmachine
Copy link
Contributor

Pinging @elastic/security-detection-engine (Team:Detection Engine)

@yctercero
Copy link
Contributor

Hey @banderror ! Would it be ok to assign this one to Rules Management to look into?

@banderror
Copy link
Contributor

@yctercero Of course, it's the feature we added so we'll address the performance concerns as well. Thank you @vitaliidm!

@banderror banderror changed the title [Security Solution][Detection Engine] large number of related integrations can cause significant performance impact on rule creation/edit form [Security Solution] Large number of related integrations can impact performance on rule creation/edit form May 21, 2024
@banderror banderror added impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. Team:Detections and Resp Security Detection Response Team Team:Detection Rule Management Security Detection Rule Management Team Feature:Rule Creation Security Solution Detection Rule Creation workflow Feature:Rule Edit Security Solution Detection Rule Editing workflow 8.15 candidate and removed triage_needed labels May 21, 2024
@elasticmachine
Copy link
Contributor

Pinging @elastic/security-detections-response (Team:Detections and Resp)

@elasticmachine
Copy link
Contributor

Pinging @elastic/security-detection-rule-management (Team:Detection Rule Management)

@dplumlee dplumlee self-assigned this Apr 3, 2025
kibanamachine pushed a commit to kibanamachine/kibana that referenced this issue Apr 18, 2025
…rule editing pages (elastic#217254)

## Summary

Fixes elastic#183607

Adds logic to fix the re-render performance issues caused by the related
integrations component on the rule edit and creation pages. This copies
a strategy used in elastic#180682 to fix
a similar issue with required fields. Related integrations component now
doesn't re-render when there are updates to components that don't affect
it.

#### React Profile while typing in query field component
![Screenshot 2025-04-04 at 8 12
38 PM](https://github.com/user-attachments/assets/9d3edcaa-4856-42df-9e6d-59bcc4785b5d)

### Checklist

Check the PR satisfies following conditions.

Reviewers should verify this PR satisfies this list as well.

- [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

---------

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
(cherry picked from commit 1b6376e)
kibanamachine pushed a commit to kibanamachine/kibana that referenced this issue Apr 18, 2025
…rule editing pages (elastic#217254)

## Summary

Fixes elastic#183607

Adds logic to fix the re-render performance issues caused by the related
integrations component on the rule edit and creation pages. This copies
a strategy used in elastic#180682 to fix
a similar issue with required fields. Related integrations component now
doesn't re-render when there are updates to components that don't affect
it.

#### React Profile while typing in query field component
![Screenshot 2025-04-04 at 8 12
38 PM](https://github.com/user-attachments/assets/9d3edcaa-4856-42df-9e6d-59bcc4785b5d)

### Checklist

Check the PR satisfies following conditions.

Reviewers should verify this PR satisfies this list as well.

- [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

---------

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
(cherry picked from commit 1b6376e)
kibanamachine pushed a commit to kibanamachine/kibana that referenced this issue Apr 18, 2025
…rule editing pages (elastic#217254)

## Summary

Fixes elastic#183607

Adds logic to fix the re-render performance issues caused by the related
integrations component on the rule edit and creation pages. This copies
a strategy used in elastic#180682 to fix
a similar issue with required fields. Related integrations component now
doesn't re-render when there are updates to components that don't affect
it.

#### React Profile while typing in query field component
![Screenshot 2025-04-04 at 8 12
38 PM](https://github.com/user-attachments/assets/9d3edcaa-4856-42df-9e6d-59bcc4785b5d)

### Checklist

Check the PR satisfies following conditions.

Reviewers should verify this PR satisfies this list as well.

- [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

---------

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
(cherry picked from commit 1b6376e)
davismcphee pushed a commit to davismcphee/kibana that referenced this issue Apr 22, 2025
…rule editing pages (elastic#217254)

## Summary

Fixes elastic#183607

Adds logic to fix the re-render performance issues caused by the related
integrations component on the rule edit and creation pages. This copies
a strategy used in elastic#180682 to fix
a similar issue with required fields. Related integrations component now
doesn't re-render when there are updates to components that don't affect
it.

#### React Profile while typing in query field component
![Screenshot 2025-04-04 at 8 12
38 PM](https://github.com/user-attachments/assets/9d3edcaa-4856-42df-9e6d-59bcc4785b5d)



### Checklist

Check the PR satisfies following conditions. 

Reviewers should verify this PR satisfies this list as well.

- [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

---------

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
9.1 candidate bug Fixes for quality problems that affect the customer experience Feature:Rule Creation Security Solution Detection Rule Creation workflow Feature:Rule Edit Security Solution Detection Rule Editing workflow impact:medium Addressing this issue will have a medium level of impact on the quality/strength of our product. performance Team:Detection Engine Security Solution Detection Engine Area Team:Detection Rule Management Security Detection Rule Management Team Team:Detections and Resp Security Detection Response Team Team: SecuritySolution Security Solutions Team working on SIEM, Endpoint, Timeline, Resolver, etc.
Projects
None yet
7 participants