org.elasticsearch.index.shard.recovery
Class RecoveryTarget

java.lang.Object
  extended by org.elasticsearch.common.component.AbstractComponent
      extended by org.elasticsearch.index.shard.recovery.RecoveryTarget

public class RecoveryTarget
extends AbstractComponent

The recovery target handles recoveries of peer shards of the shard+node to recover to.

Note, it can be safely assumed that there will only be a single recovery per shard (index+id) and not several of them (since we don't allocate several shard replicas to the same node).


Nested Class Summary
static class RecoveryTarget.Actions
           
static interface RecoveryTarget.RecoveryListener
           
 
Field Summary
 
Fields inherited from class org.elasticsearch.common.component.AbstractComponent
componentSettings, logger, settings
 
Constructor Summary
RecoveryTarget(Settings settings, ThreadPool threadPool, TransportService transportService, IndicesService indicesService, IndicesLifecycle indicesLifecycle)
           
 
Method Summary
 RecoveryStatus peerRecoveryStatus(ShardId shardId)
           
 void startRecovery(StartRecoveryRequest request, boolean fromRetry, RecoveryTarget.RecoveryListener listener)
           
 
Methods inherited from class org.elasticsearch.common.component.AbstractComponent
nodeName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

RecoveryTarget

@Inject
public RecoveryTarget(Settings settings,
                             ThreadPool threadPool,
                             TransportService transportService,
                             IndicesService indicesService,
                             IndicesLifecycle indicesLifecycle)
Method Detail

peerRecoveryStatus

public RecoveryStatus peerRecoveryStatus(ShardId shardId)

startRecovery

public void startRecovery(StartRecoveryRequest request,
                          boolean fromRetry,
                          RecoveryTarget.RecoveryListener listener)