Skip to content

alert-mgmt-14: single alert rule update + delete-by-ID#13

Open
sradco wants to merge 1 commit intoalert-mgmt-13-docs-ci-e2efrom
alert-mgmt-14-single-rule
Open

alert-mgmt-14: single alert rule update + delete-by-ID#13
sradco wants to merge 1 commit intoalert-mgmt-13-docs-ci-e2efrom
alert-mgmt-14-single-rule

Conversation

@sradco
Copy link
Owner

@sradco sradco commented Feb 25, 2026

Alert Management API — Part 14/14: PATCH/DELETE /rules/{ruleId} (single rule)

Summary

  • PATCH /api/v1/alerting/rules/{ruleId} handler: single-rule update supporting alerting rule changes, drop/restore toggle, and classification patch in one request
  • DELETE /api/v1/alerting/rules/{ruleId} handler: single-rule delete by ID
  • Update routing: attempts platform update first, falls back to user-defined on NotAllowedError (same pattern as bulk update)
  • Per-field response: returns rule ID with status code and message for granular error reporting
  • Two new route registrations in router.go
  • Unit tests for both handlers including validation, error, platform/user-defined, and classification scenarios

Dependencies

This PR is part of a stacked series. Please review in order.

  1. alert-mgmt-01: k8s foundation + health stub skeleton
    2–13. Pending — alert queries, relabel/health, management foundation, endpoints, CRUD, classification, platform update, bulk update, docs/CI/e2e
    14 . → This PR — PATCH/DELETE /rules/{ruleId} (single rule)

@sradco sradco force-pushed the alert-mgmt-13-docs-ci-e2e branch from 133781c to c1aa685 Compare February 25, 2026 22:35
@sradco sradco force-pushed the alert-mgmt-14-single-rule branch from b8ebc48 to cacc1a3 Compare February 25, 2026 22:35
@sradco sradco force-pushed the alert-mgmt-13-docs-ci-e2e branch from c1aa685 to bd693a6 Compare February 25, 2026 22:52
@sradco sradco force-pushed the alert-mgmt-14-single-rule branch from cacc1a3 to 0a8c965 Compare February 25, 2026 22:52
@sradco sradco force-pushed the alert-mgmt-13-docs-ci-e2e branch from bd693a6 to 10139d8 Compare February 25, 2026 23:17
@sradco sradco force-pushed the alert-mgmt-14-single-rule branch from 0a8c965 to a8e9b58 Compare February 25, 2026 23:17
@sradco sradco force-pushed the alert-mgmt-13-docs-ci-e2e branch from 10139d8 to aa409e1 Compare February 25, 2026 23:34
@sradco sradco force-pushed the alert-mgmt-14-single-rule branch from a8e9b58 to 7a14299 Compare February 25, 2026 23:34
@sradco sradco force-pushed the alert-mgmt-13-docs-ci-e2e branch from aa409e1 to 63b0924 Compare February 25, 2026 23:47
@sradco sradco force-pushed the alert-mgmt-14-single-rule branch from 7a14299 to 78f93f8 Compare February 25, 2026 23:47
@sradco sradco force-pushed the alert-mgmt-13-docs-ci-e2e branch from 63b0924 to b1fdfb4 Compare February 25, 2026 23:57
@sradco sradco force-pushed the alert-mgmt-14-single-rule branch from 78f93f8 to 4d15eeb Compare February 25, 2026 23:57
@sradco sradco force-pushed the alert-mgmt-13-docs-ci-e2e branch from b1fdfb4 to 3ac18c0 Compare February 26, 2026 14:42
@sradco sradco force-pushed the alert-mgmt-14-single-rule branch from 4d15eeb to 281349b Compare February 26, 2026 14:42
@sradco sradco force-pushed the alert-mgmt-13-docs-ci-e2e branch from 3ac18c0 to 26ce67f Compare February 26, 2026 14:47
@sradco sradco force-pushed the alert-mgmt-14-single-rule branch from 281349b to 7cddc0c Compare February 26, 2026 14:47
@sradco sradco force-pushed the alert-mgmt-13-docs-ci-e2e branch from 26ce67f to 4a09657 Compare February 27, 2026 11:44
@sradco sradco force-pushed the alert-mgmt-14-single-rule branch from 7cddc0c to 0b1688e Compare February 27, 2026 11:44
@sradco sradco force-pushed the alert-mgmt-13-docs-ci-e2e branch from 4a09657 to 854ed0c Compare February 27, 2026 11:57
@sradco sradco force-pushed the alert-mgmt-14-single-rule branch from 0b1688e to c3cae66 Compare February 27, 2026 11:57
@sradco sradco force-pushed the alert-mgmt-13-docs-ci-e2e branch from 854ed0c to 65fe1c8 Compare February 27, 2026 11:59
@sradco sradco force-pushed the alert-mgmt-14-single-rule branch from c3cae66 to 6e4c042 Compare February 27, 2026 11:59
@sradco sradco force-pushed the alert-mgmt-13-docs-ci-e2e branch from 65fe1c8 to 1340083 Compare February 27, 2026 12:10
@sradco sradco force-pushed the alert-mgmt-14-single-rule branch from 6e4c042 to e814a67 Compare February 27, 2026 12:10
@sradco sradco force-pushed the alert-mgmt-13-docs-ci-e2e branch from 1340083 to 722eb82 Compare February 27, 2026 12:29
@sradco sradco force-pushed the alert-mgmt-14-single-rule branch from e814a67 to fdf4860 Compare February 27, 2026 12:29
@sradco sradco force-pushed the alert-mgmt-13-docs-ci-e2e branch from 722eb82 to 5b5dbc4 Compare February 27, 2026 13:12
@sradco sradco force-pushed the alert-mgmt-14-single-rule branch from fdf4860 to a7a6ffc Compare February 27, 2026 13:12
@sradco sradco force-pushed the alert-mgmt-13-docs-ci-e2e branch from 5b5dbc4 to eb40e18 Compare March 1, 2026 19:05
@sradco sradco force-pushed the alert-mgmt-14-single-rule branch from a7a6ffc to 139b443 Compare March 1, 2026 19:05
@sradco sradco force-pushed the alert-mgmt-13-docs-ci-e2e branch from eb40e18 to f5efdf2 Compare March 1, 2026 20:21
@sradco sradco force-pushed the alert-mgmt-14-single-rule branch 2 times, most recently from 31b2d04 to 81e5e9c Compare March 1, 2026 21:08
@sradco sradco force-pushed the alert-mgmt-13-docs-ci-e2e branch from f5efdf2 to 63f77d3 Compare March 1, 2026 21:08
@sradco sradco force-pushed the alert-mgmt-14-single-rule branch from 81e5e9c to 9ade599 Compare March 2, 2026 09:26
@sradco sradco force-pushed the alert-mgmt-13-docs-ci-e2e branch from 63f77d3 to 49ee8dd Compare March 2, 2026 09:26
Signed-off-by: Shirly Radco <sradco@redhat.com>
Signed-off-by: João Vilaça <jvilaca@redhat.com>
Signed-off-by: Aviv Litman <alitman@redhat.com>
Co-authored-by: AI Assistant <noreply@cursor.com>
@sradco sradco force-pushed the alert-mgmt-13-docs-ci-e2e branch from 49ee8dd to b97de66 Compare March 2, 2026 10:04
@sradco sradco force-pushed the alert-mgmt-14-single-rule branch from 9ade599 to b8e9698 Compare March 2, 2026 10:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant