Skip to content

Commit

Permalink
HBASE-28076 NPE on initialization error in RecoveredReplicationSource…
Browse files Browse the repository at this point in the history
…Shipper (#5397)

Signed-off-by: Viraj Jasani <vjasani@apache.org>
  • Loading branch information
stoty authored and virajjasani committed Sep 14, 2023
1 parent c43fe7c commit 3ba7336
Showing 1 changed file with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,10 @@ private void terminate(String reason, Exception cause) {
"Closing worker for wal group " + this.walGroupId + " because an error occurred: " + reason,
cause);
}
entryReader.interrupt();
Threads.shutdown(entryReader, sleepForRetries);
if (entryReader != null) {
entryReader.interrupt();
Threads.shutdown(entryReader, sleepForRetries);
}
this.interrupt();
Threads.shutdown(this, sleepForRetries);
LOG.info("ReplicationSourceWorker {} terminated", this.getName());
Expand Down

0 comments on commit 3ba7336

Please sign in to comment.