class DCAwareRoundRobinPolicy
Augments
LoadBalancingPolicy
Members
Constructor
A data-center aware Round-robin load balancing policy. This policy provides round-robin queries over the node of the local data center. It also includes in the query plans returned a configurable number of hosts in the remote data centers, but those are always tried after the local nodes. In other words, this policy guarantees that no host in a remote data center will be queried unless no host in the local data center can be reached.
Methods
getDistance
(Host
host)
Returns the distance depending on the datacenter.
It returns an iterator that yields local nodes first and remotes nodes afterwards. The amount of remote nodes returned will depend on the usedHostsPerRemoteDc