FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

Support custom dead-letter-queue names for self-provisioned SQS/RabbitMQ queues by ambroziepaval · Pull Request #1033 · hookdeck/outpost · GitHub

Support custom dead-letter-queue names for self-provisioned SQS/RabbitMQ queues - #1033

Merged
alexluong merged 3 commits into
hookdeck:mainfrom
ambroziepaval:feat/configurable-mq-dlq-names
Aug 13, 2026
Merged

Support custom dead-letter-queue names for self-provisioned SQS/RabbitMQ queues#1033
alexluong merged 3 commits into
hookdeck:mainfrom
ambroziepaval:feat/configurable-mq-dlq-names

Conversation

Copy link
Copy Markdown
Contributor

Note: I haven't opened an issue for this first; happy to file one if that's preferred, or to close/rework this MR if you would rather take a different approach. Posting the implementation directly since it was small enough to just try out. Open to feedback, alternative designs if this direction makes sense.

Why
When Outpost self-provisions its internal delivery and log queues, it also auto-creates a DLQ for each, but the DLQ name is currently hardcoded as a derived suffix (<queue>-dlq for SQS, <queue>.dlq for RabbitMQ), with no way to override it.

If you're self-provisioning, it seems reasonable that you'd want to control the name of every resource Outpost creates, not just the main queues. Our organization has its own naming standard for dead-letter queues driven by infra/security policy (dead_letter-<queue_name>), which doesn't match what's assumed here, and we suspect other self-hosters run into the same kind of mismatch with their own conventions. Without an override, the only options are to fight the convention or build workarounds outside Outpost just to get provisioning to comply.

Wanted to check: is this something you'd be open to supporting, and if so, does this approach look right, or would you prefer a different shape (e.g. a full name-pattern/template instead of a fixed override, or a single shared suffix config instead of per-queue)?

What changed
Added optional config fields, symmetric to the existing *_DELIVERY_QUEUE / *_LOG_QUEUE settings, that let operators name each DLQ explicitly:

  • AWS_SQS_DELIVERY_DLQ / AWS_SQS_LOG_DLQ
  • RABBITMQ_DELIVERY_DLQ / RABBITMQ_LOG_DLQ

When unset, behavior is unchanged — Outpost falls back to the existing derived name (<queue>-dlq / <queue>.dlq), so this is purely additive and backward compatible.

…bbitMQ

Adds AWS_SQS_DELIVERY_DLQ/AWS_SQS_LOG_DLQ and RABBITMQ_DELIVERY_DLQ/RABBITMQ_LOG_DLQ
so operators whose org naming conventions don't match the hardcoded <queue>-dlq /
<queue>.dlq suffixes can set the DLQ name explicitly, instead of working around it
externally. Falls back to the existing derived name when unset.

Generated with AI

Co-Authored-By: Claude <noreply@anthropic.com>

Copy link
Copy Markdown
Collaborator

hi there, thanks for opening the PR, I think the motivation is reasonable. Let me think through the approach and share more soon!

alexluong left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

This approach works great! Can we apply the same approach to GCP and Azure as well? For Azure, I believe DLQ is a part of the subscription itself. I think we should add some sort of comment or something to make it explicit that we don't accept DLQ config instead of forgetting about it.

If you're not comfortable with GCP/Azure, I can follow up on that for you as well, no worries. Let me know how you'd like to proceed.

ambroziepaval pushed a commit to ambroziepaval/outpost that referenced this pull request Aug 12, 2026
Addresses review feedback on hookdeck#1033:

- Move the "override or derive" fallback from mqinfra's dlqName() helpers into
  getDLQName() in the config layer, so the resolved name is available to callers.
  mqinfra now provisions the name it is given; naming policy lives in one place.
- Log the resolved delivery/log DLQ names in the startup configuration summary
  for SQS and RabbitMQ, per the convention in logging.go.
- Add config-layer unit tests for DLQ name resolution (derive, override,
  no-leak-between-queue-types, empty cases) and set DLQ explicitly in the
  mqinfra integration tests now that the layer no longer derives it.

Generated with AI

Co-Authored-By: Claude <noreply@anthropic.com>
Addresses review feedback on hookdeck#1033:

- Resolve DLQ names in the config layer's getDLQName() so the effective name is
  available to callers, and define each provider's naming convention once in
  mqinfra (DefaultAWSSQSDLQName / DefaultRabbitMQDLQName), used by both layers.
  The mqinfra DLQ field stays optional and still falls back to the convention,
  so constructing the infra config directly keeps working as before.
- Log the resolved delivery/log DLQ names in the startup configuration summary
  for SQS and RabbitMQ, per the convention in logging.go.
- Add config-layer unit tests for DLQ name resolution: explicit override,
  fallback to the default, no leaking between queue types, and empty cases.

Generated with AI

Co-Authored-By: Claude <noreply@anthropic.com>
ambroziepaval force-pushed the feat/configurable-mq-dlq-names branch from fe47bb1 to eebab80 Compare August 12, 2026 09:45

Copy link
Copy Markdown
Contributor Author

Azure: confirmed there's no DLQ entity to name: Declare only sets DeadLetteringOnMessageExpiration + MaxDeliveryCount, and consumption uses azservicebus.SubQueueDeadLetter (Azure's fixed $DeadLetterQueue)

GCP: want your call on the shape first, since it creates two DLQ resources and already names topics/subscriptions independently:

  1. *_DLQ_TOPIC + *_DLQ_SUBSCRIPTION (4 vars) — consistent within GCP
  2. *_DLQ only, subscription stays derived as -sub — parity with SQS/RabbitMQ

Copy link
Copy Markdown
Collaborator

Let's go with option 1!

*_DLQ_TOPIC + *_DLQ_SUBSCRIPTION (4 vars) — consistent within GCP

…b/Sub

Extends the SQS/RabbitMQ DLQ naming config to GCP Pub/Sub, using separate
topic and subscription settings to match how GCP names its main resources:

  GCP_PUBSUB_DELIVERY_DLQ_TOPIC / GCP_PUBSUB_DELIVERY_DLQ_SUBSCRIPTION
  GCP_PUBSUB_LOG_DLQ_TOPIC      / GCP_PUBSUB_LOG_DLQ_SUBSCRIPTION

Both are optional and fall back to the existing '<topic>-dlq' and
'<dlq-topic>-sub' conventions, now defined once in mqinfra and shared with the
config layer. The derived subscription follows the resolved DLQ topic, so
overriding only the topic keeps the pair consistent.

Azure Service Bus takes no DLQ name settings: it dead-letters into each
subscription's built-in $DeadLetterQueue sub-queue, whose name is fixed by the
platform. Noted in the config struct so the omission reads as deliberate.

Also logs the resolved GCP DLQ names at startup and documents the new settings.

Generated with AI

Co-Authored-By: Claude <noreply@anthropic.com>

alexluong left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

👌 🙏

alexluong merged commit 6654ff5 into hookdeck:main Aug 13, 2026
4 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
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.

2 participants


Back | FazBrowse Home | New Git URL