[Metrics UI] Fixes for editing alerts in alert management#64597
[Metrics UI] Fixes for editing alerts in alert management#64597simianhacker merged 4 commits intoelastic:masterfrom
Conversation
phillipb
left a comment
There was a problem hiding this comment.
Can't clear the alert per selection on the edit screen.
| compressed | ||
| > | ||
| <MetricsExplorerGroupBy | ||
| onChange={onGroupByChange} |
There was a problem hiding this comment.
There's actually a bug in the underlying alert library that won't let us setAlertParams('groupBy', undefined), so this is causing a bug with clearing out the group by field in edit. We should update:
kibana/x-pack/plugins/infra/public/components/alerting/metrics/expression.tsx
Lines 151 to 152 in 0db04a7
setAlertParams('groupBy', group || '');.
The bug in alerting is here:
phillipb
left a comment
There was a problem hiding this comment.
My bad, my comment wasn't clear enough.
| } | ||
|
|
||
| setAlertParams('groupBy', md.currentOptions.groupBy); | ||
| setAlertParams('groupBy', md.currentOptions.groupBy || ''); |
There was a problem hiding this comment.
This call was actually not the problem. The one that needs to be updated is the onGroupByChange here:
kibana/x-pack/plugins/infra/public/components/alerting/metrics/expression.tsx
Lines 148 to 153 in 12aae67
💚 Build SucceededHistory
To update your PR or re-run it, just comment with: |
Summary
This PR closes #64012 by setting the
sourceIdwhen it's not properly set and this also fixes the missing filter and group-by fields.