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

[SecuritySolution] Fix timeline saving / prevent epic from crashing #171674

Conversation

janmonschke
Copy link
Contributor

@janmonschke janmonschke commented Nov 21, 2023

Summary

Fixes #168194

Under some circumstance, when navigating to the timelines page, we would get a runtime exception for state.tableById[action.id] not being defined. When that happened, the redux store would be in a broken state.

This PR makes the responsible destructuring assignment more save.

@janmonschke janmonschke added release_note:fix Team:Threat Hunting:Investigations Security Solution Investigations Team backport:prev-minor Backport to (8.x) the previous minor version (i.e. one version back from main) ci:cloud-deploy Create or update a Cloud deployment v8.11.0 v8.12.0 v8.12.1 labels Nov 21, 2023
@janmonschke janmonschke self-assigned this Nov 21, 2023
Copy link
Contributor

@michaelolo24 michaelolo24 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for fixing!

@janmonschke janmonschke marked this pull request as ready for review November 21, 2023 18:21
@janmonschke janmonschke requested a review from a team as a code owner November 21, 2023 18:21
@janmonschke janmonschke enabled auto-merge (squash) November 21, 2023 18:42
Copy link
Contributor

@michaelolo24 michaelolo24 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Double approve! 👍🏾

@janmonschke
Copy link
Contributor Author

@elasticmachine merge upstream

@kibana-ci
Copy link
Collaborator

kibana-ci commented Nov 21, 2023

💛 Build succeeded, but was flaky

Failed CI Steps

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 12.8MB 12.8MB +176.0B

History

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

cc @janmonschke

@janmonschke janmonschke merged commit 10f4228 into elastic:main Nov 21, 2023
kibanamachine pushed a commit to kibanamachine/kibana that referenced this pull request Nov 21, 2023
…lastic#171674)

## Summary

Fixes elastic#168194

Under some circumstance, when navigating to the timelines page, we would
get a runtime exception for `state.tableById[action.id]` not being
defined. When that happened, the redux store would be in a broken state.

This PR makes the responsible destructuring assignment more save.

(cherry picked from commit 10f4228)
@kibanamachine
Copy link
Contributor

💚 All backports created successfully

Status Branch Result
8.11

Note: Successful backport PRs will be merged automatically after passing CI.

Questions ?

Please refer to the Backport tool documentation

jpdjere pushed a commit to jpdjere/kibana that referenced this pull request Nov 22, 2023
…shing (elastic#171674) (elastic#171692)

# Backport

This will backport the following commits from `main` to `8.11`:
- [[SecuritySolution] Fix timeline saving / prevent epic from crashing
(elastic#171674)](elastic#171674)

<!--- Backport version: 8.9.7 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT [{"author":{"name":"Jan
Monschke","email":"[email protected]"},"sourceCommit":{"committedDate":"2023-11-21T21:42:00Z","message":"[SecuritySolution]
Fix timeline saving / prevent epic from crashing (elastic#171674)\n\n##
Summary\r\n\r\nFixes
https://github.com/elastic/kibana/issues/168194\r\n\r\nUnder some
circumstance, when navigating to the timelines page, we would\r\nget a
runtime exception for `state.tableById[action.id]` not being\r\ndefined.
When that happened, the redux store would be in a broken
state.\r\n\r\nThis PR makes the responsible destructuring assignment
more
save.","sha":"10f422836be9690201cdea2fbccfc94adb4cd6a4","branchLabelMapping":{"^v8.12.0$":"main","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:fix","Team:Threat
Hunting:Investigations","backport:prev-minor","ci:cloud-deploy","v8.11.0","v8.12.0","v8.12.1","v8.11.2"],"number":171674,"url":"https://github.com/elastic/kibana/pull/171674","mergeCommit":{"message":"[SecuritySolution]
Fix timeline saving / prevent epic from crashing (elastic#171674)\n\n##
Summary\r\n\r\nFixes
https://github.com/elastic/kibana/issues/168194\r\n\r\nUnder some
circumstance, when navigating to the timelines page, we would\r\nget a
runtime exception for `state.tableById[action.id]` not being\r\ndefined.
When that happened, the redux store would be in a broken
state.\r\n\r\nThis PR makes the responsible destructuring assignment
more
save.","sha":"10f422836be9690201cdea2fbccfc94adb4cd6a4"}},"sourceBranch":"main","suggestedTargetBranches":["8.11","8.12"],"targetPullRequestStates":[{"branch":"8.11","label":"v8.11.0","labelRegex":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"},{"branch":"main","label":"v8.12.0","labelRegex":"^v8.12.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/171674","number":171674,"mergeCommit":{"message":"[SecuritySolution]
Fix timeline saving / prevent epic from crashing (elastic#171674)\n\n##
Summary\r\n\r\nFixes
https://github.com/elastic/kibana/issues/168194\r\n\r\nUnder some
circumstance, when navigating to the timelines page, we would\r\nget a
runtime exception for `state.tableById[action.id]` not being\r\ndefined.
When that happened, the redux store would be in a broken
state.\r\n\r\nThis PR makes the responsible destructuring assignment
more
save.","sha":"10f422836be9690201cdea2fbccfc94adb4cd6a4"}},{"branch":"8.12","label":"v8.12.1","labelRegex":"^v(\\d+).(\\d+).\\d+$","isSourceBranch":false,"state":"NOT_CREATED"}]}]
BACKPORT-->

Co-authored-by: Jan Monschke <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport:prev-minor Backport to (8.x) the previous minor version (i.e. one version back from main) ci:cloud-deploy Create or update a Cloud deployment release_note:fix Team:Threat Hunting:Investigations Security Solution Investigations Team v8.11.0 v8.11.2 v8.12.0 v8.12.1
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Security Solution] Unable to save Timeline
4 participants