move marking recovering before creating a status

This commit is contained in:
kimchy 2010-08-20 15:24:49 +03:00
parent 4c00e89f5e
commit 4e74001bde
1 changed files with 1 additions and 1 deletions

View File

@ -143,10 +143,10 @@ public class IndexShardGatewayService extends AbstractIndexShardComponent implem
threadPool.cached().execute(new Runnable() {
@Override public void run() {
indexShard.recovering();
recoveryStatus = new RecoveryStatus();
recoveryStatus.updateStage(RecoveryStatus.Stage.INIT);
indexShard.recovering();
// we know we are on a thread, we can spin till we can engage in recovery
while (!recoveryThrottler.tryRecovery(shardId, "gateway")) {