From 2b039bd0b054c478e4688d69bac6d2e270c3c7e8 Mon Sep 17 00:00:00 2001 From: kimchy Date: Mon, 29 Nov 2010 14:33:49 +0200 Subject: [PATCH] change the default chunk size when recovering from the default 100kb to 500kb. --- .../elasticsearch/index/shard/recovery/RecoverySource.java | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/modules/elasticsearch/src/main/java/org/elasticsearch/index/shard/recovery/RecoverySource.java b/modules/elasticsearch/src/main/java/org/elasticsearch/index/shard/recovery/RecoverySource.java index 3cd2e683f84..fe04dd35d59 100644 --- a/modules/elasticsearch/src/main/java/org/elasticsearch/index/shard/recovery/RecoverySource.java +++ b/modules/elasticsearch/src/main/java/org/elasticsearch/index/shard/recovery/RecoverySource.java @@ -78,10 +78,12 @@ public class RecoverySource extends AbstractComponent { this.transportService = transportService; this.indicesService = indicesService; - this.fileChunkSize = componentSettings.getAsBytesSize("file_chunk_size", new ByteSizeValue(100, ByteSizeUnit.KB)); + this.fileChunkSize = componentSettings.getAsBytesSize("file_chunk_size", new ByteSizeValue(500, ByteSizeUnit.KB)); this.translogBatchSize = componentSettings.getAsInt("translog_batch_size", 100); this.compress = componentSettings.getAsBoolean("compress", true); + logger.debug("using file_chunk_size [{}], translog_batch_size [{}], and compress [{}]", fileChunkSize, translogBatchSize, compress); + transportService.registerHandler(Actions.START_RECOVERY, new StartRecoveryTransportRequestHandler()); }