-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
[ResponseOps][Alerts] Fix muted alerts query using wrong filter #204182
[ResponseOps][Alerts] Fix muted alerts query using wrong filter #204182
Conversation
Pinging @elastic/response-ops (Team:ResponseOps) |
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.
Tested and LGTM! What do you think of adding an e2e to cover this bug?
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.
Tested, LGTM 👍
return http.post<FindRulesResponse>(INTERNAL_FIND_RULES_URL, { | ||
body: JSON.stringify({ | ||
rule_type_ids: params.ruleIds, | ||
filter: JSON.stringify(filterNode), |
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.
The snapshot in the tests will fail. Could you also add a test where there are multiple ruleIds
? The current one only tests ruleIds: ['foo']
.
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.
Done! 🙂
💔 Build Failed
Failed CI StepsHistory
|
I added an API integration test. The combination of unit (using the correct filter) + integration (correct muted alert instance ids in rules find API) should cover this case pretty well 🙂 |
Starting backport for target branches: 8.x |
💔 All backports failed
Manual backportTo create the backport manually run:
Questions ?Please refer to the Backport tool documentation |
…tic#204182) ## Summary Reverts the `getMutedAlerts` filter to use rule ids instead of rule type ids that caused the muted alerts state to be always empty. ## To verify 1. Create a rule that fire alerts 2. Navigate to `Stack management > Alerts` 3. Click on any alert actions menu (•••) 4. Toggle on and off the alert muted state and check that the action updates accordingly and the slashed bell icon appears in the status cell when muted ## Release note Fix alert mute/unmute action
Friendly reminder: Looks like this PR hasn’t been backported yet. |
💚 All backports created successfully
Note: Successful backport PRs will be merged automatically after passing CI. Questions ?Please refer to the Backport tool documentation |
Looks like this PR has a backport PR but it still hasn't been merged. Please merge it ASAP to keep the branches relatively in sync. |
1 similar comment
Looks like this PR has a backport PR but it still hasn't been merged. Please merge it ASAP to keep the branches relatively in sync. |
Summary
Reverts the
getMutedAlerts
filter to use rule ids instead of rule type ids that caused the muted alerts state to be always empty.To verify
Stack management > Alerts
Release note
Fix alert mute/unmute action