Skip to content

fix(monitor): skip a missing Service Bus subscription per target (closes #3565) - #3589

Merged
clabonte merged 1 commit into
mainfrom
fix/issue-3565-missing-subscription-per-target
Nov 15, 2026
Merged

clabonte merged 1 commit into
mainfrom
fix/issue-3565-missing-subscription-per-target

Conversation

@clabonte

Copy link
Copy Markdown
Contributor

Root cause

ServiceBusDlqAdapter and QueueStalledAdapter iterate their targets and let the first transport error escape. One retired or not-yet-deployed subscription (MessagingEntityNotFoundError from a peek, ResourceNotFoundError from a management read) failed the whole check: the remaining targets went unread and the environment's watermark stayed put.

Fix

Both adapters catch those two missing-entity errors per target (matched by class name, so no Azure SDK import), record the target in skipped_targets with a "subscription not found" reason, and keep reading. The run summary already prints skipped_targets, so the operator still sees the missing subscription on every run. Any other transport error still fails the check.

Tests

  • tests/test_service_bus_missing_subscription.py — a missing subscription is skipped and reported while the other targets still yield artifacts, for both check types; a non-missing transport error still raises. Fails on unchanged code.

Verification

  • scripts/smoke-test.sh: 5078 tests OK (skipped=4), smoke test OK.

Closes #3565.

🤖 Generated with Claude Code

…ead of failing the check

Closes #3565. `ServiceBusDlqAdapter` and `QueueStalledAdapter` iterate their
targets and let the first transport error escape, so one retired or
not-yet-deployed subscription (`MessagingEntityNotFoundError` from a peek,
`ResourceNotFoundError` from a management read) failed the whole check: the
remaining targets went unread and the environment's watermark stayed put.

Both adapters now catch those two missing-entity errors per target (matched
by class name, so no Azure SDK import), record the target in
`skipped_targets` with a "subscription not found" reason, and keep reading.
The run summary already prints `skipped_targets` for each check. Any other
transport error still fails the check as before.

Tests:
- tests/test_service_bus_missing_subscription.py — a missing subscription is
  skipped and reported while the other targets still yield artifacts, for both
  check types; a non-missing transport error still raises.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@clabonte
clabonte merged commit 648d9bc into main Nov 15, 2026
7 checks passed
@clabonte
clabonte deleted the fix/issue-3565-missing-subscription-per-target branch November 15, 2026 12:07
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.

monitor: one missing subscription fails the whole dlq and queue-stalled check

1 participant