Module org.elasticsearch.server
Class ConcurrentRebalanceAllocationDecider
java.lang.Object
org.elasticsearch.cluster.routing.allocation.decider.AllocationDecider
org.elasticsearch.cluster.routing.allocation.decider.ConcurrentRebalanceAllocationDecider
Similar to the
ClusterRebalanceAllocationDecider this
AllocationDecider controls the number of currently in-progress
re-balance (shard relocation) operations and restricts node allocations
if the configured threshold is reached. Frozen and non-frozen shards are
considered separately. The default number of concurrent rebalance operations
is set to 2 for non-frozen shards. For frozen shards, the default is
the same setting as non-frozen shards, until set explicitly.
Re-balance operations can be controlled in real-time via the cluster update API using
cluster.routing.allocation.cluster_concurrent_rebalance and
cluster.routing.allocation.cluster_concurrent_frozen_rebalance.
Iff either setting is set to -1 the number of concurrent re-balance operations
within the setting's category (frozen or non-frozen) are unlimited.
-
Field Summary
FieldsModifier and TypeFieldDescriptionSame as cluster_concurrent_rebalance, but applies separately to frozen tier shards Defaults to the same value as normal concurrent rebalance, if unspecifiedstatic final String -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncanRebalance(RoutingAllocation allocation) We allow a limited number of concurrent shard relocations, per the cluster settingCLUSTER_ROUTING_ALLOCATION_CLUSTER_CONCURRENT_REBALANCE_SETTING.canRebalance(ShardRouting shardRouting, RoutingAllocation allocation) Returns aDecisionwhether the given shard routing can be re-balanced to the given allocation.Methods inherited from class org.elasticsearch.cluster.routing.allocation.decider.AllocationDecider
canAllocate, canAllocate, canAllocate, canAllocateReplicaWhenThereIsRetentionLease, canForceAllocateDuringReplace, canForceAllocatePrimary, canRemain, getForcedInitialShardAllocationToNodes, shouldAutoExpandToNode
-
Field Details
-
NAME
- See Also:
-
CLUSTER_ROUTING_ALLOCATION_CLUSTER_CONCURRENT_REBALANCE_SETTING
-
CLUSTER_ROUTING_ALLOCATION_CLUSTER_CONCURRENT_FROZEN_REBALANCE_SETTING
public static final Setting<Integer> CLUSTER_ROUTING_ALLOCATION_CLUSTER_CONCURRENT_FROZEN_REBALANCE_SETTINGSame as cluster_concurrent_rebalance, but applies separately to frozen tier shards Defaults to the same value as normal concurrent rebalance, if unspecified
-
-
Constructor Details
-
ConcurrentRebalanceAllocationDecider
-
-
Method Details
-
canRebalance
Description copied from class:AllocationDeciderReturns aDecisionwhether the given shard routing can be re-balanced to the given allocation. The default isDecision.ALWAYS.- Overrides:
canRebalancein classAllocationDecider
-
canRebalance
We allow a limited number of concurrent shard relocations, per the cluster settingCLUSTER_ROUTING_ALLOCATION_CLUSTER_CONCURRENT_REBALANCE_SETTING. Returns aDecision.THROTTLEdecision if the limit is exceeded, otherwise returnsDecision.YES.- Overrides:
canRebalancein classAllocationDecider- Returns:
Decision.ALWAYSis returned by default if not overridden.
-