Make use of hasLinkedAlerts in incident tabs
What does this MR do and why?
Describe in detail what your merge request does and why.
IncidentTabs
immediately makes a call to check for any linked alerts on load. Previously this information was used to determine if the AlertsTab
should be rendered, alternatively, the new behaviour checked for hasLinkedAlerts
which was already being passed to the frontend to determine if AlertsTab
should be rendered or not.
No UX changed.
Some test refactoring.
Screenshots or screen recordings
Screenshots are required for UI changes, and strongly recommended for all other merge requests.
With Alerts | No Alerts |
---|---|
How to set up and validate locally
Numbered steps to set up and validate the change are strongly suggested.
- Ensure you are running enterprise edition
- Go to a project's settings, then Monitor
- Expand Alerts
- Add a new integration, HTTP endpoint is fine, give a mock name, in customise alert you can paste
{ "events": [{ "application": "Name of application" }] }
- Click "save and create test alert
- Navigate to Monitor -> Alerts
- Open the new test alert 7.a (If it isn't there, you can navigate back to integration settings, open the settings for the new integration, go to the tab called "send test alert" and paste this
{ "events": [{ "application": "Name of application" }] }
and send - in the Alert click "create incident on the top right of the alert page
- Alert Tab should new be rendered
- To test without alerts, create an incident from Monitor -> Incidents -> new incident. Alert tab should not be rendered when there are no alerts
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
issue: #367856