This is an automated email from the ASF dual-hosted git repository.

technoboy pushed a commit to branch branch-3.1
in repository https://gitbox.apache.org/repos/asf/pulsar.git


The following commit(s) were added to refs/heads/branch-3.1 by this push:
     new 0eb1267077d [fix][broker] replicator leak when removeReplicator in 
NonPersistentTopic (#21205)
0eb1267077d is described below

commit 0eb1267077d8580eae14bbcedfdf35a9a3419bea
Author: hanmz <[email protected]>
AuthorDate: Thu Sep 21 10:04:41 2023 +0800

    [fix][broker] replicator leak when removeReplicator in NonPersistentTopic 
(#21205)
---
 .../apache/pulsar/broker/service/nonpersistent/NonPersistentTopic.java   | 1 +
 1 file changed, 1 insertion(+)

diff --git 
a/pulsar-broker/src/main/java/org/apache/pulsar/broker/service/nonpersistent/NonPersistentTopic.java
 
b/pulsar-broker/src/main/java/org/apache/pulsar/broker/service/nonpersistent/NonPersistentTopic.java
index c764283cb44..42c11fa14ca 100644
--- 
a/pulsar-broker/src/main/java/org/apache/pulsar/broker/service/nonpersistent/NonPersistentTopic.java
+++ 
b/pulsar-broker/src/main/java/org/apache/pulsar/broker/service/nonpersistent/NonPersistentTopic.java
@@ -634,6 +634,7 @@ public class NonPersistentTopic extends AbstractTopic 
implements Topic, TopicPol
 
         replicators.get(remoteCluster).disconnect().thenRun(() -> {
             log.info("[{}] Successfully removed replicator {}", name, 
remoteCluster);
+            replicators.remove(remoteCluster);
 
         }).exceptionally(e -> {
             log.error("[{}] Failed to close replication producer {} {}", 
topic, name, e.getMessage(), e);

Reply via email to