Skip to content

Commit

Permalink
[pulsar-broker] Handle NPE in unblock stuck subscrption task when dis…
Browse files Browse the repository at this point in the history
…patcher is not created (apache#10430)
  • Loading branch information
rdhabalia authored May 4, 2021
1 parent 504c4f3 commit 9982492
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1098,7 +1098,7 @@ public boolean checkIsCanDeleteConsumerPendingAck(PositionImpl position) {
}

public boolean checkAndUnblockIfStuck() {
return dispatcher.checkAndUnblockIfStuck();
return dispatcher != null ? dispatcher.checkAndUnblockIfStuck() : false;
}

private static final Logger log = LoggerFactory.getLogger(PersistentSubscription.class);
Expand Down

0 comments on commit 9982492

Please sign in to comment.