Package org.opensearch.indices.recovery
Class StartRecoveryRequest
java.lang.Object
org.opensearch.core.transport.TransportMessage
org.opensearch.transport.TransportRequest
org.opensearch.indices.recovery.StartRecoveryRequest
- All Implemented Interfaces:
org.opensearch.core.common.io.stream.Writeable
,TaskAwareRequest
Represents a request for starting a peer recovery.
- Opensearch.api:
-
Nested Class Summary
Nested classes/interfaces inherited from class org.opensearch.transport.TransportRequest
TransportRequest.Empty
Nested classes/interfaces inherited from interface org.opensearch.core.common.io.stream.Writeable
org.opensearch.core.common.io.stream.Writeable.Reader<V>, org.opensearch.core.common.io.stream.Writeable.WriteableRegistry, org.opensearch.core.common.io.stream.Writeable.Writer<V>
-
Constructor Summary
ConstructorsConstructorDescriptionStartRecoveryRequest
(org.opensearch.core.common.io.stream.StreamInput in) StartRecoveryRequest
(org.opensearch.core.index.shard.ShardId shardId, String targetAllocationId, DiscoveryNode sourceNode, DiscoveryNode targetNode, Store.MetadataSnapshot metadataSnapshot, boolean primaryRelocation, long recoveryId, long startingSeqNo) Construct a request for starting a peer recovery. -
Method Summary
Methods inherited from class org.opensearch.transport.TransportRequest
getParentTask, setParentTask
Methods inherited from class org.opensearch.core.transport.TransportMessage
remoteAddress, remoteAddress
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.opensearch.tasks.TaskAwareRequest
createTask, getDescription, setParentTask
-
Constructor Details
-
StartRecoveryRequest
- Throws:
IOException
-
StartRecoveryRequest
public StartRecoveryRequest(org.opensearch.core.index.shard.ShardId shardId, String targetAllocationId, DiscoveryNode sourceNode, DiscoveryNode targetNode, Store.MetadataSnapshot metadataSnapshot, boolean primaryRelocation, long recoveryId, long startingSeqNo) Construct a request for starting a peer recovery.- Parameters:
shardId
- the shard ID to recovertargetAllocationId
- the allocation id of the target shardsourceNode
- the source node to remover fromtargetNode
- the target node to recover tometadataSnapshot
- the Lucene metadataprimaryRelocation
- whether or not the recovery is a primary relocationrecoveryId
- the recovery IDstartingSeqNo
- the starting sequence number
-
-
Method Details
-
recoveryId
public long recoveryId() -
shardId
public org.opensearch.core.index.shard.ShardId shardId() -
targetAllocationId
-
sourceNode
-
targetNode
-
isPrimaryRelocation
public boolean isPrimaryRelocation() -
metadataSnapshot
-
startingSeqNo
public long startingSeqNo() -
writeTo
- Specified by:
writeTo
in interfaceorg.opensearch.core.common.io.stream.Writeable
- Overrides:
writeTo
in classTransportRequest
- Throws:
IOException
-