summaryrefslogtreecommitdiffstats
path: root/config-model/src/main
diff options
context:
space:
mode:
authorGeir Storli <geirst@verizonmedia.com>2020-07-02 17:02:26 +0200
committerGitHub <noreply@github.com>2020-07-02 17:02:26 +0200
commit5ea9ab0b823b7bf634f07e89ad900cefc301d1e2 (patch)
treeef660e19573d0a55666ff8d7abfc07515dc2e1da /config-model/src/main
parent12fbf5b3265de130d3374c239a19fe1cd9425e73 (diff)
parent6c765d0f5f2266171beec0c3df620c961fd79b0d (diff)
Merge pull request #13785 from vespa-engine/toregge/require-restart-if-distance-metric-is-changed-without-hnsw-index-enabled
Require restart if distance metric is changed when hnsw index is not enabled.
Diffstat (limited to 'config-model/src/main')
-rw-r--r--config-model/src/main/java/com/yahoo/vespa/model/application/validation/change/search/AttributeChangeValidator.java2
1 files changed, 1 insertions, 1 deletions
diff --git a/config-model/src/main/java/com/yahoo/vespa/model/application/validation/change/search/AttributeChangeValidator.java b/config-model/src/main/java/com/yahoo/vespa/model/application/validation/change/search/AttributeChangeValidator.java
index 4f3e100ce75..5d790c74f18 100644
--- a/config-model/src/main/java/com/yahoo/vespa/model/application/validation/change/search/AttributeChangeValidator.java
+++ b/config-model/src/main/java/com/yahoo/vespa/model/application/validation/change/search/AttributeChangeValidator.java
@@ -96,8 +96,8 @@ public class AttributeChangeValidator {
validateAttributeSetting(currAttr, nextAttr, Attribute::densePostingListThreshold, "dense-posting-list-threshold", result);
validateAttributeSetting(currAttr, nextAttr, Attribute::isEnabledOnlyBitVector, "rank: filter", result);
validateAttributeSetting(currAttr, nextAttr, AttributeChangeValidator::hasHnswIndex, "indexing: index", result);
+ validateAttributeSetting(currAttr, nextAttr, Attribute::distanceMetric, "distance-metric", result);
if (hasHnswIndex(currAttr) && hasHnswIndex(nextAttr)) {
- validateAttributeSetting(currAttr, nextAttr, Attribute::distanceMetric, "distance-metric", result);
validateAttributeHnswIndexSetting(currAttr, nextAttr, HnswIndexParams::maxLinksPerNode, "max-links-per-node", result);
validateAttributeHnswIndexSetting(currAttr, nextAttr, HnswIndexParams::neighborsToExploreAtInsert, "neighbors-to-explore-at-insert", result);
}