EventStore / EventStoreDB-Client-Java

Official Asynchronous Java 8+ Client Library for EventStoreDB 20.6+
https://eventstore.com
Apache License 2.0
63 stars 20 forks source link

Fix cluster discovery process. #261

Closed YoEight closed 8 months ago

YoEight commented 8 months ago

Fixed: Fix cluster discovery process.

This patch addresses two issues:

The client wrongfully assumed that a connection string like esdb+discover://{ip}:{port} was a single node connection. While wrong it doesn't really matter if the selected node was the leader. If it had another state, a node leader exception would have been raised and the client should reconnect to the leader of the cluster anyway.

The other issue is far more annoying because it lead the client to rule out the leader node from the gossip seed because the client code wrongly assumed that node was from a previous connection attempt that failed.

linear[bot] commented 8 months ago

DB-622 Fix cluster discovery process in the java client