The policy that decides the "query plan" for each query; that is, which nodes to try as coordinators, and in which order.
- Value parameters:
- `class`
The class of the policy. If it is not qualified, the driver assumes that it resides in the package
com.datastax.oss.driver.internal.core.loadbalancing
.- filter
A custom filter to include/exclude nodes.
- localDatacenter
The datacenter that is considered "local": the default policy will only include nodes from this datacenter in its query plans. This option can only be absent if you specified no contact points: in that case, the driver defaults to 127.0.0.1:9042, and that node's datacenter is used as the local datacenter. As soon as you provide contact points (either through the configuration or through the cluster builder), you must define the local datacenter explicitly, and initialization will fail if this property is absent. In addition, all contact points should be from this datacenter; warnings will be logged for nodes that are from a different one.
- Companion:
- object