Skip to content

Commit

Permalink
SOLR-16450: waitForState to cleanly unregister watches if there is a …
Browse files Browse the repository at this point in the history
…failure
  • Loading branch information
noblepaul committed Oct 18, 2022
1 parent 79fba55 commit 32e0f68
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1896,9 +1896,9 @@ public void waitForState(

return matches;
};
registerCollectionStateWatcher(collection, watcher);

try {
registerCollectionStateWatcher(collection, watcher);
// wait for the watcher predicate to return true, or time out
if (!latch.await(wait, unit))
throw new TimeoutException(
Expand Down

0 comments on commit 32e0f68

Please sign in to comment.