diff --git a/CHANGELOG.md b/CHANGELOG.md index 3cf0e78220f4a..30bf131e9caeb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,6 +14,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), - Faster `terms` query creation for `keyword` field with index and docValues enabled ([#19350](https://github.com/opensearch-project/OpenSearch/pull/19350)) - Refactor to move prepareIndex and prepareDelete methods to Engine class ([#19551](https://github.com/opensearch-project/OpenSearch/pull/19551)) - Omit maxScoreCollector in SimpleTopDocsCollectorContext when concurrent segment search enabled ([#19584](https://github.com/opensearch-project/OpenSearch/pull/19584)) +- Respect Replication type settings from plugins ([#19626](https://github.com/opensearch-project/OpenSearch/pull/19626)) ### Fixed - Fix Allocation and Rebalance Constraints of WeightFunction are incorrectly reset ([#19012](https://github.com/opensearch-project/OpenSearch/pull/19012)) diff --git a/server/src/main/java/org/opensearch/cluster/metadata/MetadataCreateIndexService.java b/server/src/main/java/org/opensearch/cluster/metadata/MetadataCreateIndexService.java index a889091140d12..f42d030f278d0 100644 --- a/server/src/main/java/org/opensearch/cluster/metadata/MetadataCreateIndexService.java +++ b/server/src/main/java/org/opensearch/cluster/metadata/MetadataCreateIndexService.java @@ -1139,6 +1139,8 @@ public static void updateReplicationStrategy( indexReplicationType = INDEX_REPLICATION_TYPE_SETTING.get(requestSettings); } else if (combinedTemplateSettings != null && INDEX_REPLICATION_TYPE_SETTING.exists(combinedTemplateSettings)) { indexReplicationType = INDEX_REPLICATION_TYPE_SETTING.get(combinedTemplateSettings); + } else if (INDEX_REPLICATION_TYPE_SETTING.exists(settingsBuilder)) { + indexReplicationType = ReplicationType.parseString(settingsBuilder.get(INDEX_REPLICATION_TYPE_SETTING.getKey())); } else if (CLUSTER_REPLICATION_TYPE_SETTING.exists(nodeSettings)) { indexReplicationType = CLUSTER_REPLICATION_TYPE_SETTING.get(nodeSettings); } else if (isRemoteDataAttributePresent(nodeSettings)) {