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

[Monitoring] Some progress on making alerts better in the UI #81569

Merged

Conversation

chrisronline
Copy link
Contributor

@chrisronline chrisronline commented Oct 23, 2020

Relates to #80397

This PR does a few things to improve how we surface alerts in the Stack Monitoring UI.

We currently do not handle a bunch of alerts firing at the same time well. Per @ravikesarwani's suggestion and @igoristic's suggestion, we should group this better and offer the user a way to change between the grouping.

In addition, alerts presence on the individual node/instance listing pages can be improved as well, per a suggestion.

Screenshots

Screen Shot 2020-11-20 at 9 59 09 AM

Screen Shot 2020-11-20 at 9 59 20 AM

Screen Shot 2020-11-20 at 9 59 24 AM

Screen Shot 2020-11-20 at 9 59 31 AM

Screen Shot 2020-11-20 at 9 59 34 AM

Screen Shot 2020-11-20 at 9 59 38 AM

Screen Shot 2020-11-20 at 10 00 55 AM

Screen Shot 2020-11-20 at 10 01 00 AM

Screen Shot 2020-11-20 at 10 01 05 AM

anchorPosition="downLeft"
>
<EuiContextMenu
key={`${showByNode ? 'byNode' : 'byType'}_${panels.length}`}
Copy link
Contributor

Choose a reason for hiding this comment

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

We don't need a key here since since it's not iterated (at its nested scope).

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sure, I can try to remove it. I originally added it because I saw strange behavior when toggling between the modes and React refusing to render any changes.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I ended up adding this back in because I saw the same behavior. I'd be happy to solve the issue another way if you have ideas.

Copy link
Contributor

@igoristic igoristic left a comment

Choose a reason for hiding this comment

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

@chrisronline Looking good 👍 Thank you for getting the changes in so quickly!

A couple more things:

  1. If there are multiple alert types on the node’s detail page and you disabling one of them (via the call out panel), it switches and expands the next alert type below it (might take a few seconds) with the same disabled state (even though it’s not disabled):
    Screen Shot 2020-12-11 at 10 46 54 PM
    This is after I disabled the the CPU Usage alert above it

  1. There's an empty bar if there are no alerts on the node’s detail page:
    Screen Shot 2020-12-11 at 10 50 23 PM

  1. The group by toggle switch never changes state (visually):
    Screen Shot 2020-12-11 at 8 03 00 PM

I think we should "Group by alert type" by default, and the switch should always be labeled "Group by node" which could be in either on or off state


  1. Pressing "Group by node" on the Kibana instances panel does not show the title/label any more:
    Screen Shot 2020-12-11 at 8 07 40 PM

  1. On the ES nodes listing page, "by type" shows the count for all the nodes (for that type) instead of for that specific node:
    Screen Shot 2020-12-11 at 7 59 36 PM

@chrisronline
Copy link
Contributor Author

If there are multiple alert types on the node’s detail page and you disabling one of them (via the call out panel), it switches and expands the next alert type below it (might take a few seconds) with the same disabled state (even though it’s not disabled):

This seems to be how the EuiAccordion component works. I'd suggest not attempting to fix it for this PR, but we can open an issue in EUI for this if we feel strongly.

There's an empty bar if there are no alerts on the node’s detail page:

Nice find!

The group by toggle switch never changes state (visually):

I'm sorry, I don't know what you mean. It seems to work fine for me.

I think we should "Group by alert type" by default, and the switch should always be labeled "Group by node" which could be in either on or off state

I feel like the off state isn't obvious to users. I like the idea of labeling each state explicitly. Perhaps we can change the UI toggle - it doesn't have to be a EuiSwitch if we feel that's confusing

Pressing "Group by node" on the Kibana instances panel does not show the title/label any more:

Yup, i'll fix this up.

On the ES nodes listing page, "by type" shows the count for all the nodes (for that type) instead of for that specific node:

Fixed up too

Copy link
Contributor

@igoristic igoristic left a comment

Choose a reason for hiding this comment

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

Great job! I love this new alerting experience 😍

@chrisronline
Copy link
Contributor Author

@elasticmachine merge upstream

@kibanamachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

Module Count

Fewer modules leads to a faster build time

id before after diff
monitoring 611 616 +5

Async chunks

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

id before after diff
monitoring 944.4KB 959.9KB +15.5KB

Distributable file count

id before after diff
default 47129 47889 +760

Page load bundle

Size of the bundles that are downloaded on every page load. Target size is below 100kb

id before after diff
monitoring 35.3KB 36.4KB +1.1KB

History

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

@chrisronline chrisronline merged commit 1e8f2f6 into elastic:master Dec 13, 2020
@chrisronline chrisronline deleted the monitoring/better_alerts_in_ui branch December 13, 2020 15:20
chrisronline added a commit to chrisronline/kibana that referenced this pull request Dec 13, 2020
…#81569)

* Some progress on making alerts better in the UI

* Handle edge case

* Updates

* More updates

* Show kibana instances alerts better

* Stop showing missing nodes and improve the detail alert UI

* WIP

* Fix the badge display

* Okay I think this is finally working

* Fix type issues

* Fix tests

* Fix tests

* Fix alert counts

* Fix setup mode listing

* Better detail page view of alerts

* Feedback

* Sorting

* Fix a couple small issues

* Start of unit tests

* I don't think we need this Mock type

* Fix types

* More tests

* Improve tests and fix sorting

* Make this test more resilient

* Updates after merging master

* Fix tests

* Fix types, and improve tests

* PR comments

* Remove nextStep logic

* PR feedback

* PR feedback

* Removing unnecessary changes

* Fixing bad merge issues

* Remove unused imports

* Add tooltip to alerts grouped by node

* Fix up stateFilter usage

* Code clean up

* PR feedback

* Fix state filtering in the category list

* Fix types

* Fix test

* Fix types

* Update snapshots

Co-authored-by: Kibana Machine <[email protected]>
chrisronline added a commit that referenced this pull request Dec 13, 2020
…#85719)

* Some progress on making alerts better in the UI

* Handle edge case

* Updates

* More updates

* Show kibana instances alerts better

* Stop showing missing nodes and improve the detail alert UI

* WIP

* Fix the badge display

* Okay I think this is finally working

* Fix type issues

* Fix tests

* Fix tests

* Fix alert counts

* Fix setup mode listing

* Better detail page view of alerts

* Feedback

* Sorting

* Fix a couple small issues

* Start of unit tests

* I don't think we need this Mock type

* Fix types

* More tests

* Improve tests and fix sorting

* Make this test more resilient

* Updates after merging master

* Fix tests

* Fix types, and improve tests

* PR comments

* Remove nextStep logic

* PR feedback

* PR feedback

* Removing unnecessary changes

* Fixing bad merge issues

* Remove unused imports

* Add tooltip to alerts grouped by node

* Fix up stateFilter usage

* Code clean up

* PR feedback

* Fix state filtering in the category list

* Fix types

* Fix test

* Fix types

* Update snapshots

Co-authored-by: Kibana Machine <[email protected]>

Co-authored-by: Kibana Machine <[email protected]>
gmmorris added a commit to gmmorris/kibana that referenced this pull request Dec 14, 2020
* master: (116 commits)
  Fix UX E2E tests (elastic#85722)
  Increasing default api key removalDelay to 1h (elastic#85576)
  align cors settings names with elasticsearch (elastic#85738)
  unskip tests and make sure submit is not triggered too quickly (elastic#85567)
  Row trigger 2 (elastic#83167)
  Add session id to audit log (elastic#85451)
  [TSVB] Fields lists do not populate all the times (elastic#85530)
  [Visualize] Removes the external link icon from OSS badges (elastic#85580)
  fixes EQL tests (elastic#85712)
  [APM] enable 'log_level' for Go (elastic#85511)
  ini `1.3.5` -> `1.3.7` (elastic#85707)
  Fix fleet route protections (elastic#85626)
  [Monitoring] Some progress on making alerts better in the UI (elastic#81569)
  [Security Solution] Refactor Timeline Notes to use EuiCommentList (elastic#85256)
  [Security Solution][Detections][Threshold Rules] Threshold rule exceptions (elastic#85103)
  [Security Solution] Alerts details (elastic#83963)
  skip flaky suite (elastic#62060)
  skip flaky suite (elastic#85098)
  skip flaky suite (elastic#84020)
  skip flaky suite (elastic#85671)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants