-
Notifications
You must be signed in to change notification settings - Fork 97
Fix ACLP Alerts Implementation #878
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
base: main
Are you sure you want to change the base?
Conversation
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.
Pull request overview
This PR addresses issues with ACLP (Alert and Monitoring) alerts functionality by reverting alert channels listing due to API breaking changes, fixing struct definitions, and adding a helper function to wait for alert definition status.
Changes:
- Reverted alert channels listing functionality to be re-implemented later
- Fixed type definitions in alert definition structs (Status, EntityIDs)
- Added
WaitForAlertDefinitionStatusReady()function for polling alert definition status
Reviewed changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| waitfor.go | Added new function to wait for alert definition to reach ready status |
| test/integration/monitor_alert_definitions_test.go | Commented out alert channel queries and used hardcoded channel ID |
| test/integration/fixtures/TestMonitorAlertDefinition_CreateWithIdempotency.yaml | Updated test fixture with new timestamps and user IDs |
| test/integration/fixtures/TestMonitorAlertDefinition.yaml | Updated test fixture data with new entity IDs and additional test alerts |
| test/integration/fixtures/TestMonitorAlertChannels_List.yaml | Removed entire fixture file content |
| monitor_alert_definitions.go | Added AlertDefinitionStatus type, fixed EntityIDs type, added AlertChannelEnvelope struct |
| monitor_alert_channels.go | New file with commented-out alert channel code for future implementation |
| alert_channels.go | Deleted file containing alert channel implementation |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
📝 Description
This PR did a few things to fix ACLP alerts related functions:
WaitForAlertDefinitionStatusReady()functionThis PR is the dependency of the terraform PR: linode/terraform-provider-linode#2234
✔️ How to Test