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 (apache#5397)

Signed-off-by: Viraj Jasani <[email protected]>
(cherry picked from commit 3ba7336)
Change-Id: Ifaae6c53b1fa4dcadc7f2f8c86242ae0344fed9e
  • Loading branch information
stoty authored and Jenkins committed Sep 25, 2023
1 parent 8a3f1bd commit 161d879
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 161d879

Please sign in to comment.