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/06/16 07:14:08 UTC
[GitHub] [pulsar] poorbarcode commented on a diff in pull request #20583: [fix][broker] Fix one potential to add duplicated consumer
poorbarcode commented on code in PR #20583:
URL: https://github.com/apache/pulsar/pull/20583#discussion_r1231873184
##########
pulsar-broker/src/main/java/org/apache/pulsar/broker/service/ServerCnx.java:
##########
@@ -1184,7 +1184,6 @@ protected void handleSubscribe(final CommandSubscribe subscribe) {
ServerError error = getErrorCodeWithErrorLog(existingConsumerFuture, true,
String.format("Consumer subscribe failure. remoteAddress: %s, subscription: %s",
remoteAddress, subscriptionName));
- consumers.remove(consumerId, existingConsumerFuture);
Review Comment:
There are three clients in your example, the pulsar client maintains its own connection pool, which means the `client1` will not use the same connection as `client2` or `client3`.
The code you changed is the code of `ServerCnx`(this object is not shared across multi clients), so it will not affect other consumers of other clients
--
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