Open cvybhu opened 1 year ago
Note that we'd like to deprecate SimpleStrategy (see https://github.com/scylladb/scylladb/issues/5224 and others).
@Lorak-mmk / @wprzytula since we shouldn't support SimpleStartegy with multiDC, can we close this one?
@Lorak-mmk / @wprzytula since we shouldn't support SimpleStartegy with multiDC, can we close this one?
If the reason for that is that Scylla won't support SimpleStrategy with multiDC, then remember that Cassandra will still support it, and we want to correctly support Cassandra as well. Right?
Yes, but also for Cassandra it's highly advisable not using SimpleStrategy with Multi DC configuration.
By default the driver performs each query with the
LocalQuorum
consistency.This choice of consistency causes trouble for multi-dc clusters with
SimpleStrategy
. Imagine a cluster with 3 datacenters (dc1
,dc2
,dc3
), with 3 nodes in each datacenter.Now let's say there's a keyspace:
'replication_factor': 3
means that for each partition there are 3 nodes in the whole cluster that are replicas for this partition. Let's say the replicas are: A (indc1
), B (indc1
) and C (indc2
).Now the user performs a query, and let's say that the load balancing chooses C to be the coordinator. Because the query uses
LocalQuorum
as the default consistency, the query will fail - there aren't enough nodes indc2
to fulfill the consistency requirement, there would need to be at least 2.I think it would be generally better to have the default be
Quorum
instead ofLocalQuorum
. It's the safest option. Sadly changing this would count as a breaking change.