-
Notifications
You must be signed in to change notification settings - Fork 309
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
PagerDuty Migrator: Add filtering capabilities and fix user notification rule preservation #5454
Conversation
- Add filtering by team, users, and regex patterns for schedules, escalation policies, and integrations - Fix notification policy preservation behavior - Add comprehensive test coverage for new features
- Add filter_schedules, filter_escalation_policies, and filter_integrations functions - Add comprehensive test coverage for filtering functionality - Add dedicated notification rules tests
- Fix notification rules preservation behavior - Add dedicated test file for notification rules - Improve test coverage for notification policy scenarios
@@ -20,6 +20,7 @@ | |||
"Zabbix Webhook (for 5.0 and 5.2)": "zabbix", | |||
"Elastic Alerts": "elastalert", | |||
"Firebase": "fabric", | |||
"Amazon CloudWatch": "amazon_sns", |
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.
there was a request to map Amazon CloudWatch Integration in PagerDuty to our Amazon SNS Integration (apparently these are essentially the same thing?)
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.
LGTM
This PR adds filtering capabilities to the PagerDuty migrator tool and fixes user notification rule preservation behavior.
Closes https://github.com/grafana/irm/issues/612
Changes
1. Added Resource Filtering
Added the ability to filter PagerDuty resources during migration based on:
New environment variables for filtering:
Example Usage
Filter by team:
Filter by specific users:
Filter schedules by name pattern:
Filter escalation policies by name pattern:
Filter integrations by name pattern:
2. Fixed User Notification Rule Preservation
Introduces a
PRESERVE_EXISTING_USER_NOTIFICATION_RULES
config (default oftrue
). The migrator now:PRESERVE_EXISTING_USER_NOTIFICATION_RULES
is TruePRESERVE_EXISTING_USER_NOTIFICATION_RULES
is FalseExample Usage
Preserve existing notification policies (default):
Replace existing notification policies:
3. Improved Testing
Added comprehensive test coverage for filtering functionality and updated user notification rule preservation tests
Testing Done