Click or drag to resize

DefaultLoadBalancingPolicy Class

A load balancing policy designed to run against both DSE and Apache Cassandra clusters.

For most workloads, the query plan will be determined in a similar way to TokenAwarePolicy(DCAwareRoundRobinPolicy).

For graph analytics queries, this policy sets the preferred analytics graph server previously obtained by driver as the first host in the query plan. After this host, the query plan is the same as the one returned for other workloads.

Inheritance Hierarchy
SystemObject
  CassandraDefaultLoadBalancingPolicy

Namespace:  Cassandra
Assembly:  Cassandra (in Cassandra.dll) Version: 3.13.0
Syntax
C#
public class DefaultLoadBalancingPolicy : ILoadBalancingPolicy

The DefaultLoadBalancingPolicy type exposes the following members.

Constructors
  NameDescription
Public methodDefaultLoadBalancingPolicy
Creates a new datacenter aware round robin policy given the name of the local datacenter.

The name of the local datacenter provided must be the local datacenter name as known by the server.

The policy created will ignore all remote hosts.

Top
Methods
  NameDescription
Public methodDistance
Return the HostDistance for the provided host. This policy consider nodes in the local datacenter as Local and the rest is Ignored.
Public methodInitialize
Initializes the policy.
Public methodNewQueryPlan
Returns the hosts to used for a query.
Top
See Also