You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by "poorbarcode (via GitHub)" <gi...@apache.org> on 2023/08/08 05:54:18 UTC

[GitHub] [pulsar] poorbarcode commented on a diff in pull request #20951: [broker][fix] Producer is blocked on creation because backlog exceeded on topic, when dedup is enabled and no producer is there

poorbarcode commented on code in PR #20951:
URL: https://github.com/apache/pulsar/pull/20951#discussion_r1286626170


##########
pulsar-broker/src/main/java/org/apache/pulsar/broker/service/persistent/PersistentTopic.java:
##########
@@ -195,6 +195,10 @@ public class PersistentTopic extends AbstractTopic implements Topic, AddEntryCal
     private final TopicName shadowSourceTopic;
 
     static final String DEDUPLICATION_CURSOR_NAME = "pulsar.dedup";
+
+    public static boolean isDedupCursorName(String name) {
+        return name.equals(DEDUPLICATION_CURSOR_NAME);

Review Comment:
   Use `DEDUPLICATION_CURSOR_NAME .equals(curosrName)` is better, because the constant variable is never be `null`



-- 
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