Skip to content

Commit 1aa73e3

Browse files
Apache9rodenli
andcommitted
HBASE-28669 After one RegionServer restarts, another RegionServer leaks a connection to ZooKeeper (#6207)
Signed-off-by: Duo Zhang <zhangduo@apache.org> Co-authored-by: rodenli <rodenli@tencent.com> (cherry picked from commit 4da8880)
1 parent dbf8acf commit 1aa73e3

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

hbase-server/src/main/java/org/apache/hadoop/hbase/replication/regionserver/RecoveredReplicationSource.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,9 @@ void tryFinish() {
149149
boolean allTasksDone = workerThreads.values().stream().allMatch(w -> w.isFinished());
150150
if (allTasksDone) {
151151
this.getSourceMetrics().clear();
152+
if (this.getReplicationEndpoint() != null) {
153+
this.getReplicationEndpoint().stop();
154+
}
152155
manager.removeRecoveredSource(this);
153156
LOG.info("Finished recovering queue {} with the following stats: {}", queueId, getStats());
154157
}

0 commit comments

Comments
 (0)