Skip to content

Commit 0209aec

Browse files
authored
Merge pull request #1321 from ajax-surovskyi-y/main
Fix race condition during reconnect sends UNSUB messages
2 parents 51c6aa1 + 8bb866e commit 0209aec

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/io/nats/client/impl/NatsConnection.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -638,7 +638,7 @@ public void run() {
638638
}
639639

640640
this.currentServer = cur;
641-
this.serverAuthErrors.remove(resolved); // reset on successful connection
641+
this.serverAuthErrors.clear(); // reset on successful connection
642642
updateStatus(Status.CONNECTED); // will signal status change, we also signal in finally
643643
} finally {
644644
statusLock.unlock();

0 commit comments

Comments
 (0)