From cf70761abf94aea56e189664dd723bada6bb2791 Mon Sep 17 00:00:00 2001 From: Britta Weber Date: Fri, 15 Jan 2016 10:54:28 +0100 Subject: [PATCH] we assume from now on that settings are reset if we pass empty settings --- .../java/org/elasticsearch/index/MergePolicySettingsTests.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/core/src/test/java/org/elasticsearch/index/MergePolicySettingsTests.java b/core/src/test/java/org/elasticsearch/index/MergePolicySettingsTests.java index 10c3d51162b..266204af833 100644 --- a/core/src/test/java/org/elasticsearch/index/MergePolicySettingsTests.java +++ b/core/src/test/java/org/elasticsearch/index/MergePolicySettingsTests.java @@ -114,8 +114,7 @@ public class MergePolicySettingsTests extends ESTestCase { mp.onRefreshSettings(EMPTY_SETTINGS); // update without the settings and see if we stick to the values indexSettings.updateIndexMetaData(newIndexMeta("index", EMPTY_SETTINGS)); - // this will fail because we now reset each setting which is not passed with the sttings update. are we sure this is the desired behavior? - assertEquals(((TieredMergePolicy) indexSettings.getMergePolicy()).getForceMergeDeletesPctAllowed(), MergePolicyConfig.DEFAULT_EXPUNGE_DELETES_ALLOWED + 1.0d, 0.0d); + assertEquals(((TieredMergePolicy) indexSettings.getMergePolicy()).getForceMergeDeletesPctAllowed(), MergePolicyConfig.DEFAULT_EXPUNGE_DELETES_ALLOWED, 0.0d); assertEquals(((TieredMergePolicy) mp.getMergePolicy()).getFloorSegmentMB(), new ByteSizeValue(MergePolicyConfig.DEFAULT_FLOOR_SEGMENT.mb() + 1, ByteSizeUnit.MB).mbFrac(), 0.001); assertEquals(((TieredMergePolicy) mp.getMergePolicy()).getMaxMergeAtOnce(), MergePolicyConfig.DEFAULT_MAX_MERGE_AT_ONCE-1); assertEquals(((TieredMergePolicy) mp.getMergePolicy()).getMaxMergeAtOnceExplicit(), MergePolicyConfig.DEFAULT_MAX_MERGE_AT_ONCE_EXPLICIT-1);