Module org.elasticsearch.server
Interface ShardRoutingRoleStrategy
public interface ShardRoutingRoleStrategy
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ShardRoutingRoleStrategy
A strategy that refuses to create any new shard copies, which is used (for instance) when reading shard copies from a remote node. -
Method Summary
Modifier and TypeMethodDescriptionnewEmptyRole
(int copyIndex) default ShardRouting.Role
newRestoredRole
(int copyIndex)
-
Field Details
-
NO_SHARD_CREATION
A strategy that refuses to create any new shard copies, which is used (for instance) when reading shard copies from a remote node.
-
-
Method Details
-
newEmptyRole
- Returns:
- the role for a copy of a new empty shard, where
copyIndex
is the index of the copy (0
for the primary and1..N
for replicas).
-
newReplicaRole
ShardRouting.Role newReplicaRole()- Returns:
- the role for a new replica copy of an existing shard.
-
newRestoredRole
- Returns:
- the role for a copy of a new shard being restored from snapshot, where
copyIndex
is the index of the copy (0
for the primary and1..N
for replicas).
-