Class RecoverySourceHandler
java.lang.Object
org.elasticsearch.indices.recovery.RecoverySourceHandler
RecoverySourceHandler handles the three phases of shard recovery, which is
everything relating to copying the segment files as well as sending translog
operations across the wire once the segments have been copied.
Note: There is always one source handler per recovery that handles all the
file and translog transfer. This handler is completely isolated from other recoveries
while the
RateLimiter passed via RecoverySettings is shared across recoveries
originating from this nodes to throttle the number bytes send during file transfer. The transaction log
phase bypasses the rate limiter entirely.-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionRecoverySourceHandler(IndexShard shard, RecoveryTargetHandler recoveryTarget, ThreadPool threadPool, StartRecoveryRequest request, int fileChunkSizeInBytes, int maxConcurrentFileChunks, int maxConcurrentOperations) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddListener(ActionListener<RecoveryResponse> listener)voidCancels the recovery and interrupts all eligible threads.protected voidfailEngine(IOException cause)voidrecoverToTarget(ActionListener<RecoveryResponse> listener)performs the recovery from the local engine to the targettoString()
-
Field Details
-
logger
protected final org.apache.logging.log4j.Logger logger
-
-
Constructor Details
-
RecoverySourceHandler
public RecoverySourceHandler(IndexShard shard, RecoveryTargetHandler recoveryTarget, ThreadPool threadPool, StartRecoveryRequest request, int fileChunkSizeInBytes, int maxConcurrentFileChunks, int maxConcurrentOperations)
-
-
Method Details