Interface AllocationCommand
-
- All Superinterfaces:
NamedWriteable,ToXContent,ToXContentObject,Writeable
- All Known Implementing Classes:
AbstractAllocateAllocationCommand,AllocateEmptyPrimaryAllocationCommand,AllocateReplicaAllocationCommand,AllocateStalePrimaryAllocationCommand,BasePrimaryAllocationCommand,CancelAllocationCommand,MoveAllocationCommand
public interface AllocationCommand extends NamedWriteable, ToXContentObject
A command to move shards in some way. Commands are registered inNetworkModule.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.elasticsearch.common.xcontent.ToXContent
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.Params
-
Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V>
-
-
Field Summary
-
Fields inherited from interface org.elasticsearch.common.xcontent.ToXContent
EMPTY_PARAMS
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description RerouteExplanationexecute(RoutingAllocation allocation, boolean explain)Executes the command on aRoutingAllocationsetupdefault Optional<String>getMessage()Returns any feedback the command wants to provide for logging.default StringgetWriteableName()Returns the name of the writeable objectStringname()Get the name of the command-
Methods inherited from interface org.elasticsearch.common.xcontent.ToXContent
toXContent
-
Methods inherited from interface org.elasticsearch.common.xcontent.ToXContentObject
isFragment
-
-
-
-
Method Detail
-
name
String name()
Get the name of the command- Returns:
- name of the command
-
execute
RerouteExplanation execute(RoutingAllocation allocation, boolean explain)
Executes the command on aRoutingAllocationsetup- Parameters:
allocation-RoutingAllocationto modify- Throws:
ElasticsearchException- if something happens during reconfiguration
-
getWriteableName
default String getWriteableName()
Description copied from interface:NamedWriteableReturns the name of the writeable object- Specified by:
getWriteableNamein interfaceNamedWriteable
-
-