Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,6 @@
index: test_lookup

- match: { test_lookup.settings.index.number_of_shards: "1"}
- match: { test_lookup.settings.index.auto_expand_replicas: "0-all"}

---
"Create lookup index with one shard":
Expand All @@ -196,7 +195,6 @@
index: test_lookup

- match: { test_lookup.settings.index.number_of_shards: "1"}
- match: { test_lookup.settings.index.auto_expand_replicas: "0-all"}

---
"Create lookup index with two shards":
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ public void testBasic() {
assertAcked(client().admin().indices().execute(TransportCreateIndexAction.TYPE, createRequest));
Settings settings = client().admin().indices().prepareGetSettings("hosts").get().getIndexToSettings().get("hosts");
assertThat(settings.get("index.mode"), equalTo("lookup"));
assertThat(settings.get("index.auto_expand_replicas"), equalTo("0-all"));
assertNull(settings.get("index.auto_expand_replicas"));
Map<String, String> allHosts = Map.of(
"192.168.1.2",
"Windows",
Expand Down Expand Up @@ -141,7 +141,6 @@ public void testResizeLookupIndex() {
Settings settings = client().admin().indices().prepareGetSettings("lookup-2").get().getIndexToSettings().get("lookup-2");
assertThat(settings.get("index.mode"), equalTo("lookup"));
assertThat(settings.get("index.number_of_shards"), equalTo("1"));
assertThat(settings.get("index.auto_expand_replicas"), equalTo("0-all"));

ResizeRequest split = new ResizeRequest("lookup-3", "lookup-1");
split.setResizeType(ResizeType.SPLIT);
Expand Down
5 changes: 1 addition & 4 deletions server/src/main/java/org/elasticsearch/index/IndexMode.java
Original file line number Diff line number Diff line change
Expand Up @@ -623,10 +623,7 @@ public Settings getAdditionalIndexSettings(
}
}
if (indexMode == LOOKUP) {
return Settings.builder()
.put(IndexMetadata.SETTING_NUMBER_OF_SHARDS, 1)
.put(IndexMetadata.SETTING_AUTO_EXPAND_REPLICAS, "0-all")
.build();
return Settings.builder().put(IndexMetadata.SETTING_NUMBER_OF_SHARDS, 1).build();
} else {
return Settings.EMPTY;
}
Expand Down