-
Notifications
You must be signed in to change notification settings - Fork 212
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
Schedule deletion does not work when incidents are still open #567
Comments
This is a blocker for configuring PagerDuty in code. It's a tricky one but I'd suggest that the incidents would be resolved automatically (i.e. the effect would cascade). |
When a trying to delete a Schedule that is being used by an Escalation Policy with open incidents, but additionally that Schedule gets removed from Escalation Policy to be part of another EP or just to be deleted, the Schedule’s data loses the traceability with the EP with the open incidents, because that relation is tracked through the EP snapshot created when the incident gets triggered. So, The error received from that deletion intend is the following:
Therefore, at the So, as long as an update to errors messages on this case for This has been informed to PagerDuty |
No worries, FWIW we ended up writing a custom pagerduty controller (like a k8s operator) that reconciles desired config with what is in pagerduty. it was a little tricky since the api has some gotchas like this - hit another one today: support hours need to be HH:MM:00, so 23:59:59 won't work 😄 no big deal though as we worked around them. |
Terraform Version
2.6.1
Affected Resource(s)
"pagerduty_schedule"
Terraform Configuration Files
This would be after deleting any schedule linked to an escalation policy
Debug Output
Panic Output
"Schedule can't be deleted if it's being used by an escalation policy snapshot with open incidents"
Expected Behavior
Should close incidents and remove the schedule
Actual Behavior
Schedule is not removed
Steps to Reproduce
Important Factoids
Are there anything atypical about your accounts that we should know? For example: Running in EC2 Classic? Custom version of OpenStack? Tight ACLs?
References
Are there any other GitHub issues (open or closed) or Pull Requests that should be linked here? For example:
The text was updated successfully, but these errors were encountered: