You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by "sagar-upswing (via GitHub)" <gi...@apache.org> on 2025/05/30 12:06:19 UTC

[I] [Bug] Retry topic without topic [{subscription_name}-RETRY] is getting created (brokers’ version is [only when <3.0.6, and clients’ version is >=3.0.6], related to PIP-344 compatiblity [pulsar]

sagar-upswing opened a new issue, #24369:
URL: https://github.com/apache/pulsar/issues/24369

   ### Search before reporting
   
   - [x] I searched in the [issues](https://github.com/apache/pulsar/issues) and found nothing similar.
   
   
   ### Read release policy
   
   - [x] I understand that [unsupported versions](https://pulsar.apache.org/contribute/release-policy/#supported-versions) don't get bug fixes. I will attempt to reproduce the issue on a supported version of Pulsar client and Pulsar broker.
   
   
   ### User environment
   
   Broker version - 2.11.0 (or <3.0.6)]
   Client version - 4.0.4 (or >3.0.6)
   
   ### Issue Description
   
   - Context - We are migrating from 2.11.0 to 4. We connected 4.0.4 client with 2.11.0 server
   - Expected - RETRY topics with topic name should've been created - {topic_name}-{sub_name}-RETRY (just like it was working with 2.11.0 server)
   - What happened - RETRY topics without topic name got created - {sub_name}-RETRY, we use service name as subscription name. This makes all my unrelated consumer subscriber of the same RETRY topic under same subscription.
   - Bug - Backward compatibility for for non PIP-344 brokers is incomplete,  merged [PR](https://github.com/apache/pulsar/pull/23136/files#diff-8761c864a30fab92d9116a3c965a9c383e8c527520116f605101a93f7830e083) that was meant to solve for compatibility
   As this PR the implementation these non PIP-344 brokers will always create a new metadata in case topic does not exist. Broker passes a value instead of exception. Value contains `partition = 0`.
   There is one more merged [PR](https://github.com/apache/pulsar/pull/22838/files#diff-1357b66ed34aa22cd5e680559dfcb645dce2876bdc0bda33c07f0170e7313441R171) where we have updated the logic of topic existence from `partition>0` to `if partition metadata exist` when checking for RETRY topic without topic existence for compatibility.
   My non-PIP-344 broker (2.11.0) returns metadata for the topic which does not exist. And my client (4.0.4) consider it as if topic exist and makes instead of RETRY topic without topic name is used.
   
   
   ### Error messages
   
   ```text
   
   ```
   
   ### Reproducing the issue
   
   Use client - 
   
   ### Additional information
   
   Broker version  <3.0.6
   Client version  >3.0.6
   Have multiple consumer-topic relationship with same subscription name.
   
   ### Are you willing to submit a PR?
   
   - [ ] I'm willing to submit a PR!


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Bug] Retry topic without topic ({subscription_name}-RETRY) is getting created [broker >=3.0.6, and clients’ version is <3.0.6], related to PIP-344 compatibility [pulsar]

Posted by "merlimat (via GitHub)" <gi...@apache.org>.
merlimat commented on issue #24369:
URL: https://github.com/apache/pulsar/issues/24369#issuecomment-6378776506

   Confirmed on master: `ConsumerBuilderImpl.checkDlqAlreadyExists()` (pulsar-client/src/main/java/org/apache/pulsar/client/impl/ConsumerBuilderImpl.java:112-118) treats a successful partitioned-metadata lookup of the legacy `{subscription}-RETRY` topic as "exists". When the broker does not support PIP-344, `BinaryProtoLookupService` (lines 268-277) falls back to the auto-creating lookup, and the old broker returns `{partitions: 0}` even when the topic doesn't exist, so a new client against a pre-3.0.6 broker switches to `{subscription}-RETRY` and unrelated consumers with the same subscription name share one retry topic. Likely fix: when the broker lacks PIP-344 support, don't use the fallback for this existence check (treat it as "not found", or check via the topic list), so the new `{topic}-{subscription}-RETRY` name is kept. Note this only affects clients connected to brokers older than 3.0.6.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Bug] Retry topic without topic [{subscription_name}-RETRY] is getting created (brokers’ version is [only when <3.0.6, and clients’ version is >=3.0.6], related to PIP-344 compatiblity [pulsar]

Posted by "lhotari (via GitHub)" <gi...@apache.org>.
lhotari commented on issue #24369:
URL: https://github.com/apache/pulsar/issues/24369#issuecomment-2922825721

   @poorbarcode Do you have a chance to take a look at this since this is PIP-344 related?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org