Package | Description |
---|---|
com.datastax.driver.core |
The main package for the DataStax Java driver for Cassandra.
|
com.datastax.driver.core.policies |
Policies that allow to control some of the behavior of the DataStax Java driver for Cassandra.
|
com.datastax.driver.dse |
Modifier and Type | Method and Description |
---|---|
Cluster.Builder |
Cluster.Builder.withLoadBalancingPolicy(LoadBalancingPolicy policy)
Configures the load balancing policy to use for the new cluster.
|
Modifier and Type | Interface and Description |
---|---|
interface |
ChainableLoadBalancingPolicy
A load balancing policy that wraps another policy.
|
Modifier and Type | Class and Description |
---|---|
class |
DCAwareRoundRobinPolicy
A data-center aware Round-robin load balancing policy.
|
class |
HostFilterPolicy
A load balancing policy wrapper that ensures that only hosts matching the predicate
will ever be returned.
|
class |
LatencyAwarePolicy
A wrapper load balancing policy that adds latency awareness to a child policy.
|
class |
RoundRobinPolicy
A Round-robin load balancing policy.
|
class |
TokenAwarePolicy
A wrapper load balancing policy that add token awareness to a child policy.
|
class |
WhiteListPolicy
A load balancing policy wrapper that ensure that only hosts from a provided
white list will ever be returned.
|
Modifier and Type | Method and Description |
---|---|
static LoadBalancingPolicy |
Policies.defaultLoadBalancingPolicy()
The default load balancing policy.
|
LoadBalancingPolicy |
TokenAwarePolicy.getChildPolicy() |
LoadBalancingPolicy |
LatencyAwarePolicy.getChildPolicy() |
LoadBalancingPolicy |
HostFilterPolicy.getChildPolicy() |
LoadBalancingPolicy |
ChainableLoadBalancingPolicy.getChildPolicy()
Returns the child policy.
|
LoadBalancingPolicy |
Policies.getLoadBalancingPolicy()
The load balancing policy in use.
|
Modifier and Type | Method and Description |
---|---|
static LatencyAwarePolicy.Builder |
LatencyAwarePolicy.builder(LoadBalancingPolicy childPolicy)
Creates a new latency aware policy builder given the child policy
that the resulting policy should wrap.
|
static HostFilterPolicy |
HostFilterPolicy.fromDCBlackList(LoadBalancingPolicy childPolicy,
Iterable<String> dcs)
Create a new policy that wraps the provided child policy but only "forbids" hosts
whose DC belongs to the provided list.
|
static HostFilterPolicy |
HostFilterPolicy.fromDCWhiteList(LoadBalancingPolicy childPolicy,
Iterable<String> dcs)
Create a new policy that wraps the provided child policy but only "allows" hosts
whose DC belongs to the provided list.
|
Policies.Builder |
Policies.Builder.withLoadBalancingPolicy(LoadBalancingPolicy loadBalancingPolicy)
Sets the load balancing policy.
|
Constructor and Description |
---|
Builder(LoadBalancingPolicy childPolicy)
Creates a new latency aware policy builder given the child policy
that the resulting policy wraps.
|
HostFilterPolicy(LoadBalancingPolicy childPolicy,
com.google.common.base.Predicate<Host> predicate)
Create a new policy that wraps the provided child policy but only "allows" hosts
matching the predicate.
|
TokenAwarePolicy(LoadBalancingPolicy childPolicy)
Creates a new
TokenAware policy with shuffling of replicas. |
TokenAwarePolicy(LoadBalancingPolicy childPolicy,
boolean shuffleReplicas)
Creates a new
TokenAware policy. |
WhiteListPolicy(LoadBalancingPolicy childPolicy,
Collection<InetSocketAddress> whiteList)
Creates a new policy that wraps the provided child policy but only "allows" hosts
from the provided while list.
|
Modifier and Type | Class and Description |
---|---|
class |
DseLoadBalancingPolicy
Adds DSE-specific load balancing abilities on top of another policy.
|
Modifier and Type | Method and Description |
---|---|
static LoadBalancingPolicy |
DseConfiguration.defaultLoadBalancingPolicy()
Builds an instance of the default load balancing policy used for DSE.
|
LoadBalancingPolicy |
DseLoadBalancingPolicy.getChildPolicy() |
Modifier and Type | Method and Description |
---|---|
DseCluster.Builder |
DseCluster.Builder.withLoadBalancingPolicy(LoadBalancingPolicy policy)
Configures the load balancing policy to use for the new DSE cluster.
|
Constructor and Description |
---|
DseLoadBalancingPolicy(LoadBalancingPolicy childPolicy)
Build a new instance.
|