Skip to content

Commit

Permalink
CURATOR-720: Stop retry if client is closed (#511)
Browse files Browse the repository at this point in the history
  • Loading branch information
HoustonPutman authored Dec 12, 2024
1 parent 6a27ff0 commit 72fd977
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -399,6 +399,9 @@ void removeParentWatcher(Watcher watcher) {
public void internalBlockUntilConnectedOrTimedOut() throws InterruptedException {
long waitTimeMs = connectionTimeoutMs;
while (!state.isConnected() && (waitTimeMs > 0)) {
if (!started.get()) {
throw new IllegalStateException("Client is not started or has been closed");
}
final CountDownLatch latch = new CountDownLatch(1);
Watcher tempWatcher = new Watcher() {
@Override
Expand Down

0 comments on commit 72fd977

Please sign in to comment.