-
Notifications
You must be signed in to change notification settings - Fork 8.2k
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
[Security Solution] Resolve JS warnings triggered by incorrect state changed #148552
Conversation
## Summary This pr is a part of #147261: Replace donut charts with Lens: This is behind feature flag `chartEmbeddablesEnabled ` Items to verify: 1. If the queries and filters from the global search box are applied. 2. If the correct alert index is applied by different spaced. 3. Visualization actions working correctly. Detection and Response dashboard: <img width="1662" alt="Screenshot 2023-01-09 at 09 21 56" src="https://user-images.githubusercontent.com/6295984/211275765-8177e9bd-3623-4bb2-b1d9-8a3044d523a0.png"> Host details: <img width="1666" alt="Screenshot 2023-01-09 at 09 21 38" src="https://user-images.githubusercontent.com/6295984/211275770-be95353f-4d1b-410a-b7bf-b232692af1ab.png"> User details: <img width="1662" alt="Screenshot 2023-01-09 at 09 21 19" src="https://user-images.githubusercontent.com/6295984/211275773-dd0bcaaf-58e6-404b-b010-d1c464cbd101.png"> Network details: <img width="1663" alt="Screenshot 2023-01-09 at 09 20 47" src="https://user-images.githubusercontent.com/6295984/211275775-0fd39ac3-e977-44bd-bd40-304463dce613.png"> Known issues: 1. Not showing legend for alerts donut charts at the moment: There is a logic in Lens that it doesn't show the legend item if its value is zero. 4. JS warnings triggered by incorrect state changed. Fixed by #148552 5. No label in the donut by default when open in Lens - Lens doesn't support displaying a label in the middle of the donut chart by default, so it is currently available in Security Solution. 6. Applying filters or extra action while clicking the donut is not available atm ### Checklist Delete any items that are not applicable to this PR. - [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: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
commit fc3b886 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Tue Jan 10 14:02:01 2023 +0000 replace alerts by severity table with lens commit a1464c2 Merge: e0bdf32 076d60d Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Tue Jan 10 12:41:36 2023 +0000 Merge branch 'histogram-with-lens' of github.com:angorayc/kibana into histogram-with-lens commit e0bdf32 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Tue Jan 10 12:40:45 2023 +0000 replace donut on alerts page commit 076d60d Merge: f5cb4e0 09e10b8 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Tue Jan 10 11:53:38 2023 +0000 Merge branch 'main' of github.com:elastic/kibana into histogram-with-lens commit f5cb4e0 Merge: 119dbe7 010f93b Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Tue Jan 10 11:15:40 2023 +0000 Merge branch 'histogram-with-lens' of github.com:angorayc/kibana into histogram-with-lens commit 09e10b8 Author: Angela Chuang <6295984+angorayc@users.noreply.github.com> Date: Tue Jan 10 11:13:21 2023 +0000 [SecuritySolution] Replace donuts with Lens (elastic#148519) ## Summary This pr is a part of elastic#147261: Replace donut charts with Lens: This is behind feature flag `chartEmbeddablesEnabled ` Items to verify: 1. If the queries and filters from the global search box are applied. 2. If the correct alert index is applied by different spaced. 3. Visualization actions working correctly. Detection and Response dashboard: <img width="1662" alt="Screenshot 2023-01-09 at 09 21 56" src="https://user-images.githubusercontent.com/6295984/211275765-8177e9bd-3623-4bb2-b1d9-8a3044d523a0.png"> Host details: <img width="1666" alt="Screenshot 2023-01-09 at 09 21 38" src="https://user-images.githubusercontent.com/6295984/211275770-be95353f-4d1b-410a-b7bf-b232692af1ab.png"> User details: <img width="1662" alt="Screenshot 2023-01-09 at 09 21 19" src="https://user-images.githubusercontent.com/6295984/211275773-dd0bcaaf-58e6-404b-b010-d1c464cbd101.png"> Network details: <img width="1663" alt="Screenshot 2023-01-09 at 09 20 47" src="https://user-images.githubusercontent.com/6295984/211275775-0fd39ac3-e977-44bd-bd40-304463dce613.png"> Known issues: 1. Not showing legend for alerts donut charts at the moment: There is a logic in Lens that it doesn't show the legend item if its value is zero. 4. JS warnings triggered by incorrect state changed. Fixed by elastic#148552 5. No label in the donut by default when open in Lens - Lens doesn't support displaying a label in the middle of the donut chart by default, so it is currently available in Security Solution. 6. Applying filters or extra action while clicking the donut is not available atm ### Checklist Delete any items that are not applicable to this PR. - [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: kibanamachine <42973632+kibanamachine@users.noreply.github.com> commit ef2faad Author: Marco Antonio Ghiani <marcoantonio.ghiani01@gmail.com> Date: Tue Jan 10 10:39:50 2023 +0100 [Infrastructure UI]: Add feedback button for hosts page (elastic#148555) ## 📓 Summary Closes elastic#148379 This PR replaces the existing link to get feedback on the forum with a button that brings on a form with predefined questions on the Hosts page. ## 🧪 Testing Navigate to the `Hosts`view and click the top-right button saying "_Tell us what you think!_". <img width="1502" alt="solution" src="https://user-images.githubusercontent.com/34506779/211347429-c8f338c3-8bb0-4304-8b58-6d140e301554.png"> Co-authored-by: Marco Antonio Ghiani <marcoantonio.ghiani@elastic.co> Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com> commit 5c8b6f2 Author: James Gowdy <jgowdy@elastic.co> Date: Tue Jan 10 09:33:56 2023 +0000 [ML] Fix modal titles (elastic#147855) An EUI change has caused modal titles to no longer be implicitly wrapped in a header tag. This change adds a `h2` to all modal titles. **Old** <img width="824" alt="image" src="https://user-images.githubusercontent.com/22172091/208673148-3da918c4-f1d7-48c5-8afd-022b912b49fc.png"> **New** <img width="857" alt="image" src="https://user-images.githubusercontent.com/22172091/208673087-1b8cba03-504b-4505-ac65-0fcfcce4b99b.png"> commit 010f93b Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Thu Dec 8 15:15:43 2022 +0000 render histogram with lens commit 119dbe7 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Sun Jan 8 10:02:57 2023 +0000 fix types commit 0891f07 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Sat Jan 7 23:39:27 2023 +0000 unit test commit d2023fa Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Sat Jan 7 23:32:23 2023 +0000 fetch session id only when vis inabled commit 82b4ddb Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Sat Jan 7 22:38:44 2023 +0000 refetch commit d896cb0 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Sat Jan 7 19:47:18 2023 +0000 remove eslint comment commit d619b30 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Sat Jan 7 19:19:41 2023 +0000 unit tests commit 075ef5f Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Thu Jan 5 15:46:55 2023 +0000 styling commit 4d4a5cf Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Thu Jan 5 15:16:54 2023 +0000 update snapshot commit aead88e Merge: a91bf4f 1c5febb Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Thu Jan 5 14:51:07 2023 +0000 Merge branch 'histogram-with-lens' of github.com:angorayc/kibana into histogram-with-lens commit a91bf4f Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Thu Jan 5 14:50:39 2023 +0000 update snapshot commit 29da009 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Thu Jan 5 14:42:32 2023 +0000 fix types commit 1c18042 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Thu Jan 5 12:47:56 2023 +0000 styling commit 1c5febb Author: kibanamachine <42973632+kibanamachine@users.noreply.github.com> Date: Tue Jan 3 17:43:29 2023 +0000 [CI] Auto-commit changed files from 'node scripts/precommit_hook.js --ref HEAD~1..HEAD --fix' commit 73e17de Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Tue Jan 3 17:38:29 2023 +0000 pass extra filters to Lens commit 789c0c8 Merge: dfb9e8f 0c8c4d7 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Tue Jan 3 17:14:34 2023 +0000 Merge branch 'main' of github.com:elastic/kibana into histogram-with-lens commit dfb9e8f Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Tue Jan 3 15:48:36 2023 +0000 render rule preview with lens commit c753bd8 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Fri Dec 30 16:02:53 2022 +0000 add total alerts count commit 785712e Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Thu Dec 29 18:26:50 2022 +0000 replace alerts donut charts commit c31b77d Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Wed Dec 28 11:08:34 2022 +0000 fix unit tests commit 7dbc50d Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Fri Dec 23 14:02:52 2022 +0000 add unit tests commit 1b50b16 Merge: 55f0cf2 03ddae8 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Thu Dec 22 14:15:02 2022 +0000 Merge branch 'main' of github.com:elastic/kibana into histogram-with-lens commit 55f0cf2 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Thu Dec 22 14:14:45 2022 +0000 update snapshots commit 153f139 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Thu Dec 22 12:46:22 2022 +0000 add unit tests commit da58b26 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Thu Dec 22 12:13:17 2022 +0000 rename props commit 26da70b Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Thu Dec 22 12:12:53 2022 +0000 update events chart commit 445cb99 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Thu Dec 22 11:44:13 2022 +0000 clean up commit 761998f Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Thu Dec 22 11:05:57 2022 +0000 fix unit tests commit 5fc4ece Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Wed Dec 21 17:36:39 2022 +0000 fix types commit 73424d7 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Wed Dec 21 17:01:40 2022 +0000 add no data prompt commit 0b18236 Merge: a07eefe 5f5291d Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Tue Dec 20 17:07:17 2022 +0000 Merge branch 'histogram-with-lens' of github.com:angorayc/kibana into histogram-with-lens commit a07eefe Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Tue Dec 20 17:06:32 2022 +0000 extra actions commit 84dce3f Merge: b68afd1 53e42eb Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Tue Dec 20 16:12:24 2022 +0000 Merge branch 'main' of github.com:elastic/kibana into histogram-with-lens commit 5f5291d Author: kibanamachine <42973632+kibanamachine@users.noreply.github.com> Date: Tue Dec 20 15:21:19 2022 +0000 [CI] Auto-commit changed files from 'node scripts/precommit_hook.js --ref HEAD~1..HEAD --fix' commit b68afd1 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Tue Dec 20 15:15:31 2022 +0000 replace alerts histograms with Lens commit 7b39762 Merge: 6376733 3192372 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Fri Dec 16 09:58:19 2022 +0000 Merge branch 'main' of github.com:elastic/kibana into histogram-with-lens commit 6376733 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Fri Dec 16 09:58:15 2022 +0000 replace alert histograms with lens commit 62bd659 Author: Angela Chuang <yi-chun.chuang@elastic.co> Date: Thu Dec 8 15:15:43 2022 +0000 render histogram with lens
Pinging @elastic/security-threat-hunting (Team:Threat Hunting) |
Pinging @elastic/security-solution (Team: SecuritySolution) |
...lugins/security_solution/public/explore/users/components/kpi_users/authentications/index.tsx
Outdated
Show resolved
Hide resolved
x-pack/plugins/security_solution/public/common/components/page/use_refetch_by_session.tsx
Outdated
Show resolved
Hide resolved
…ts/kpi_users/authentications/index.tsx Co-authored-by: Steph Milovic <stephanie.milovic@elastic.co>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!! Thanks for the fix @angorayc 🚀
💛 Build succeeded, but was flaky
Failed CI StepsTest Failures
Metrics [docs]Async chunks
History
To update your PR or re-run it, just comment with: |
## Summary This pr is a part of elastic#147261: Replace donut charts with Lens: This is behind feature flag `chartEmbeddablesEnabled ` Items to verify: 1. If the queries and filters from the global search box are applied. 2. If the correct alert index is applied by different spaced. 3. Visualization actions working correctly. Detection and Response dashboard: <img width="1662" alt="Screenshot 2023-01-09 at 09 21 56" src="https://user-images.githubusercontent.com/6295984/211275765-8177e9bd-3623-4bb2-b1d9-8a3044d523a0.png"> Host details: <img width="1666" alt="Screenshot 2023-01-09 at 09 21 38" src="https://user-images.githubusercontent.com/6295984/211275770-be95353f-4d1b-410a-b7bf-b232692af1ab.png"> User details: <img width="1662" alt="Screenshot 2023-01-09 at 09 21 19" src="https://user-images.githubusercontent.com/6295984/211275773-dd0bcaaf-58e6-404b-b010-d1c464cbd101.png"> Network details: <img width="1663" alt="Screenshot 2023-01-09 at 09 20 47" src="https://user-images.githubusercontent.com/6295984/211275775-0fd39ac3-e977-44bd-bd40-304463dce613.png"> Known issues: 1. Not showing legend for alerts donut charts at the moment: There is a logic in Lens that it doesn't show the legend item if its value is zero. 4. JS warnings triggered by incorrect state changed. Fixed by elastic#148552 5. No label in the donut by default when open in Lens - Lens doesn't support displaying a label in the middle of the donut chart by default, so it is currently available in Security Solution. 6. Applying filters or extra action while clicking the donut is not available atm ### Checklist Delete any items that are not applicable to this PR. - [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: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
…changed (elastic#148552) ## Summary Found these js warning after replacing charts with Lens in elastic#148519: <img width="1671" alt="Screenshot 2023-01-09 at 15 31 17" src="https://user-images.githubusercontent.com/6295984/211345750-8c4e67ee-bf96-49d2-8bb2-0f71e5f9bcd2.png"> Wrap `search.session.start()` with useEffect to avoid incorrect state changed. ### Checklist Delete any items that are not applicable to this PR. - [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: Steph Milovic <stephanie.milovic@elastic.co>
Summary
Found these js warning after replacing charts with Lens in #148519:
Wrap
search.session.start()
with useEffect to avoid incorrect state changed.Checklist
Delete any items that are not applicable to this PR.