Rack aware-ness in the client (AER-5957)

The rack awareness feature seems great. Are the client libraries aware of it? Is there a way to specify in the client which node group to go to? For example, if I am running on two ec2 availability zones and I have them set up as separate rack groups, can I tell the client api to prefer going to a node on the same availability zone/cluster group?

1 Like

The distribution is done on the server side based on rack-aware partitioning. Currently the client cannot indicate a preference on which rack group.

@wchu,

Thanks for your reply! Are there any plans for such a feature? As you may be aware on EC2 there could be a couple of millisecond of ping between availability zones so if the client picks the wrong one that can add quite a bit to the response time.

Thanks!

Understood and this is on our radar on how to address correctly.

Thanks!

Hi, Any news about this feature?

Thanks

What is the benefit of such a feature?

Going to the same AZ as your client will decrease both latency (same data center) as well as cost (aws charges for cross-AZ traffic).

If your servers are far enough to have latency from each other, they shouldn’t be in the same cluster anyway. You would want to use XDR for that.

Rack Aware implies master goes on one rack, replica goes on the other rack. So what you want is all masters on one rack and all replicas on the other. Then all clients will read from one rack always. It may be good for some clients (in that AZ) but always high latency for others (clients from different AZ). I am still not comprehending the value of such a feature. Like Albot says - better solution is to use XDR.

Many clients recently added support for reading from a particular ‘rack’.

The Java client, for example, supports this feature as of 4.2.3.

This topic was automatically closed 6 days after the last reply. New replies are no longer allowed.