diff --git a/server/src/main/java/org/opensearch/cluster/metadata/IndexMetadata.java b/server/src/main/java/org/opensearch/cluster/metadata/IndexMetadata.java index 7210de8c70f65..759891e88039b 100644 --- a/server/src/main/java/org/opensearch/cluster/metadata/IndexMetadata.java +++ b/server/src/main/java/org/opensearch/cluster/metadata/IndexMetadata.java @@ -302,12 +302,12 @@ public void validate(final Boolean value, final Map, Object> settings final Object replicationType = settings.get(INDEX_REPLICATION_TYPE_SETTING); if (replicationType != ReplicationType.SEGMENT && value == true) { throw new IllegalArgumentException( - "Settings " + "To enable " + INDEX_REMOTE_STORE_ENABLED_SETTING.getKey() - + " cannot be enabled when " + + ", " + INDEX_REPLICATION_TYPE_SETTING.getKey() - + " is set to " - + settings.get(INDEX_REPLICATION_TYPE_SETTING) + + " should be set to " + + ReplicationType.SEGMENT ); } }