Skip to content

Commit

Permalink
[pulsar-broker] Fix deadlock on skip messages (apache#4411)
Browse files Browse the repository at this point in the history
  • Loading branch information
rdhabalia authored and merlimat committed May 31, 2019
1 parent 38503b2 commit 8385b6b
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -777,7 +777,8 @@ protected void internalSkipAllMessages(String subName, boolean authoritative) {
} else {
PersistentSubscription sub = topic.getSubscription(subName);
checkNotNull(sub);
sub.clearBacklog().get();
sub.clearBacklog().get(pulsar().getConfiguration().getZooKeeperOperationTimeoutSeconds(),
TimeUnit.SECONDS);
}
log.info("[{}] Cleared backlog on {} {}", clientAppId(), topicName, subName);
} catch (NullPointerException npe) {
Expand Down

0 comments on commit 8385b6b

Please sign in to comment.