Hi everyone We’re using Pulsar with strict schema...
# general
r
Hi everyone We’re using Pulsar with strict schema governance - each namespace has
schemaValidationEnforced=true
and
isAllowAutoUpdateSchema=false
(only under an approved process), so only admins can push schemas. Here’s the issue: when a consumer is configured with a
DeadLetterPolicy
and a message fails too many times (or is negatively acknowledged repeatedly), the client will publish the message to a dead-letter topic (default name
<topic>-<subscription>-DLQ
) after the redelivery threshold. That topic doesn’t necessarily exist ahead of time (unless created before), so when it’s first used it may trigger topic creation and/or schema registration. Because our namespace forbids auto schema updates and enforces schemas, this can fail - the consumer isn’t authorized to register the schema for the DLQ topic. To work around this, we’re creating a separate namespace (e.g.,
<namespace>-dlq
) where: •
isAllowAutoUpdateSchema=true
•
schemaValidationEnforced=false
• so consumers can safely publish DLQ messages without schema conflicts. Is this the recommended approach? Is there a cleaner way to allow DLQ schema creation while keeping production namespaces locked down? Any official guidance or community best practices would be really appreciated 🙏 Thanks!
l
Sounds like a valid use case. Please create an enhancement request to track this. It's also possible that your workaround is already the most optimal solution for addressing your use case. Contributing the documentation for the solution would be useful. For example editing content in one of https://pulsar.apache.org/docs/next/schema-overview/ , https://pulsar.apache.org/docs/next/schema-understand/ , https://pulsar.apache.org/docs/next/schema-get-started/ , https://pulsar.apache.org/docs/next/admin-api-schemas/ . You can click "Edit this page" in the page footer to start editing the content for a new pull request to https://github.com/apache/pulsar-site .