Skip to content

[7.11] [Security Solutions][Detection Engine] Removes duplicate API calls (#88420)#92601

Closed
banderror wants to merge 1 commit intoelastic:7.11from
banderror:backport/7.11/pr-88420
Closed

[7.11] [Security Solutions][Detection Engine] Removes duplicate API calls (#88420)#92601
banderror wants to merge 1 commit intoelastic:7.11from
banderror:backport/7.11/pr-88420

Conversation

@banderror
Copy link
Copy Markdown
Contributor

Backports the following commits to 7.11:

…lastic#88420)

## Summary

This removes some duplicate API calls to reduce pressure on the backend and speed up querying times within the application for the front end. This fixes some of the issues of elastic#82327, but there are several performance improvements that are going to be needed to help reduce the slowness when you have a system under a lot of pressure.

So far this removes duplication for these API calls when you are on the manage detection rules page:

```ts
api/detection_engine/rules/_find
api/detection_engine/rules/_find_statuses
api/detection_engine/tags
```

<img width="2465" alt="Screen Shot 2021-01-14 at 3 53 21 PM" src="https://user-images.githubusercontent.com/1151048/104662295-c031e080-5687-11eb-92d7-18b9ad355646.png">

* This hides the tags and searches while the page is loading to avoid duplicate calls when the pre-packaged rules counts come back
* This untangles the refetchRules from the refetchPrePackagedRulesStatus as two separate calls to avoid issues we have with re-rendering and re-calling the backend.
 
### Checklist

- [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
@banderror
Copy link
Copy Markdown
Contributor Author

Backport rejected

@banderror banderror closed this Feb 24, 2021
@banderror banderror deleted the backport/7.11/pr-88420 branch February 24, 2021 11:59
@kibanamachine
Copy link
Copy Markdown
Contributor

💚 Build Succeeded

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
securitySolution 8.5MB 8.5MB +467.0B

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport This PR is a backport of another PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants