From 2d94087f90f42cf3774a691640f1e7a527f14b0b Mon Sep 17 00:00:00 2001 From: kimchy Date: Sat, 29 Jan 2011 04:11:56 +0200 Subject: [PATCH] explicitly set optimize parameters when doing async merge --- .../elasticsearch/index/shard/service/InternalIndexShard.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/elasticsearch/src/main/java/org/elasticsearch/index/shard/service/InternalIndexShard.java b/modules/elasticsearch/src/main/java/org/elasticsearch/index/shard/service/InternalIndexShard.java index cd6b9b9821b..03375fea8ab 100644 --- a/modules/elasticsearch/src/main/java/org/elasticsearch/index/shard/service/InternalIndexShard.java +++ b/modules/elasticsearch/src/main/java/org/elasticsearch/index/shard/service/InternalIndexShard.java @@ -622,7 +622,7 @@ public class InternalIndexShard extends AbstractIndexShardComponent implements I @Override public void run() { try { // -1 means maybe merge - engine.optimize(new Engine.Optimize().maxNumSegments(-1).waitForMerge(false)); + engine.optimize(new Engine.Optimize().maxNumSegments(-1).waitForMerge(false).flush(false).refresh(false)); } catch (EngineClosedException e) { // we are being closed, ignore } catch (OptimizeFailedEngineException e) {