[8.17] [Security Solution] Fix timeline dynamic batching (#204034) | [ Security Solution ] Fix Refetch logic with new timeline batching (#205893)#205676
Merged
logeekal merged 5 commits intoelastic:8.17from Feb 6, 2025
Conversation
## Summary Handles : ### Issue with Batches - elastic#201405 - Timeline had a bug where if users fetched multiple batches and then if user adds a new column, the value of this new columns will only be fetched for the latest batch and not old batches. - This PR fixes that ✅ by cumulatively fetching the data for old batches till current batch `iff a new column has been added`. - For example, if user has already fetched the 3rd batch, data for 1st,2nd and 3rd will be fetched together when a column has been added, otherwise, data will be fetched incrementally. ### Issue with Elastic search limit - Elastic search has a limit of 10K hits at max but we throw error at 10K which should be allowed. - Error should be thrown at anything `>10K`. 10001 for example. - ✅ This PR fixes that just for timeline by allowing 10K hits. ### Removal of obsolete code Below files related to old Timeline code are removed as well: - x-pack/plugins/security_solution/public/timelines/components/timeline/footer/index.test.tsx - x-pack/plugins/security_solution/public/timelines/components/timeline/footer/index.tsx --------- Co-authored-by: Philippe Oberti <philippe.oberti@elastic.co> (cherry picked from commit 088169f) # Conflicts: # packages/kbn-babel-preset/styled_components_files.js # x-pack/plugins/security_solution/public/common/mock/mock_timeline_search_service.ts # x-pack/plugins/security_solution/public/timelines/components/timeline/footer/index.test.tsx # x-pack/plugins/security_solution/public/timelines/components/timeline/footer/index.tsx # x-pack/plugins/security_solution/public/timelines/components/timeline/tabs/query/index.tsx # x-pack/solutions/security/plugins/security_solution/public/timelines/containers/index.test.tsx
1 task
Contributor
|
@logeekal pinging just to make sure we're not loosing track of this |
Contributor
Author
…lastic#205893) ## Summary PR : elastic#204034 fixed some issues with timeline batching. It was not able to fix one of the issue with `Refetch` logic which exists in `main` ( resulting in a flaky test ) and causing some tests to fail in `8.16`, `8.17` and `8.x`. ## Issue Description There are 2 issues with below video: 1. When user updates a status of an alert, the `Refetch` only happens on the first `batch`. This behaviour is flaky currently. Even if the user is on nth batch, table will fetch 0th batch and reset the user's page back to 1. https://github.com/user-attachments/assets/eaf88a82-0e9b-4743-8b2d-60fd327a2443 3. When user clicks `Refresh` manually, then also only first (0th) `batch` is fetched, which should have rather fetched all the present batches. https://github.com/user-attachments/assets/8d578ce3-4f24-4e70-bc3a-ed6ba99167a0 ### 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
1 task
Contributor
💛 Build succeeded, but was flaky
Failed CI StepsTest Failures
Metrics [docs]Async chunks
History
|
PhilippeOberti
approved these changes
Feb 6, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Backport
This will backport the following commits from
mainto8.17:Questions ?
Please refer to the Backport tool documentation