Limit availability of page quick action to relevant incidents
What does this MR do and why?
This MR fixes two issues with the /page
quick action, which escalates incidents to on-call users.
- The
/page
quick action should only be available to GitLab Premium+. - The
/page
quick action not be available for incidents which have alerts. Alerts escalate automatically, so the associated incidents should not.
Screenshots
Incident without alert | Incident with alert |
---|---|
How to set up and validate locally
- Enable the feature flag
Feature.enable(:incident_escalations)
- Create an incident in an unlicensed project on EE (new issue with type of incident)
- Type
/page
in a comment field to see that the quick action option is not available - Create an incident from an alert
- Go to
Settings > Monitor > Alerts
- Create an alert integration & send a test alert (sample payload:
{"title": "New alert"}
) - Go to
Monitor > Alerts
& open the alert detail - Click "Create incident"
- Go to
- Type
/page
in a comment field to see that the quick action option is not available
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.
Edited by Sarah Yasonik