public abstract class AllocationDecider extends AbstractComponent
AllocationDecider
is an abstract base class that allows to make
dynamic cluster- or index-wide shard allocation decisions on a per-node
basis.deprecationLogger, logger, settings
Modifier | Constructor and Description |
---|---|
protected |
AllocationDecider(Settings settings)
Initializes a new
AllocationDecider |
Modifier and Type | Method and Description |
---|---|
Decision |
canAllocate(IndexMetaData indexMetaData,
RoutingNode node,
RoutingAllocation allocation)
Returns a
Decision whether the given shard routing can be allocated at all at this state of the
RoutingAllocation . |
Decision |
canAllocate(RoutingNode node,
RoutingAllocation allocation)
Returns a
Decision whether the given node can allow any allocation at all at this state of the
RoutingAllocation . |
Decision |
canAllocate(ShardRouting shardRouting,
RoutingAllocation allocation)
Returns a
Decision whether the given shard routing can be allocated at all at this state of the
RoutingAllocation . |
Decision |
canAllocate(ShardRouting shardRouting,
RoutingNode node,
RoutingAllocation allocation)
Returns a
Decision whether the given shard routing can be
allocated on the given node. |
Decision |
canRebalance(RoutingAllocation allocation)
Returns a
Decision whether the cluster can execute
re-balanced operations at all. |
Decision |
canRebalance(ShardRouting shardRouting,
RoutingAllocation allocation)
Returns a
Decision whether the given shard routing can be
re-balanced to the given allocation. |
Decision |
canRemain(ShardRouting shardRouting,
RoutingNode node,
RoutingAllocation allocation)
Returns a
Decision whether the given shard routing can be remain
on the given node. |
logDeprecatedSetting, logRemovedSetting, nodeName
protected AllocationDecider(Settings settings)
AllocationDecider
settings
- Settings
used by this AllocationDecider
public Decision canRebalance(ShardRouting shardRouting, RoutingAllocation allocation)
Decision
whether the given shard routing can be
re-balanced to the given allocation. The default is
Decision.ALWAYS
.public Decision canAllocate(ShardRouting shardRouting, RoutingNode node, RoutingAllocation allocation)
Decision
whether the given shard routing can be
allocated on the given node. The default is Decision.ALWAYS
.public Decision canRemain(ShardRouting shardRouting, RoutingNode node, RoutingAllocation allocation)
Decision
whether the given shard routing can be remain
on the given node. The default is Decision.ALWAYS
.public Decision canAllocate(ShardRouting shardRouting, RoutingAllocation allocation)
Decision
whether the given shard routing can be allocated at all at this state of the
RoutingAllocation
. The default is Decision.ALWAYS
.public Decision canAllocate(IndexMetaData indexMetaData, RoutingNode node, RoutingAllocation allocation)
Decision
whether the given shard routing can be allocated at all at this state of the
RoutingAllocation
. The default is Decision.ALWAYS
.public Decision canAllocate(RoutingNode node, RoutingAllocation allocation)
Decision
whether the given node can allow any allocation at all at this state of the
RoutingAllocation
. The default is Decision.ALWAYS
.public Decision canRebalance(RoutingAllocation allocation)
Decision
whether the cluster can execute
re-balanced operations at all.
Decision.ALWAYS
.Copyright © 2009–2016. All rights reserved.