diff options
author | Henning Baldersheim <balder@yahoo-inc.com> | 2024-03-15 15:54:10 +0100 |
---|---|---|
committer | Henning Baldersheim <balder@yahoo-inc.com> | 2024-03-16 23:10:33 +0000 |
commit | ebfc7be5f5b6383e02c142b7e38bc4cc57b26324 (patch) | |
tree | 3a223b1a9e7c58c2a1d56d83f7334d463ae78058 /config-model/src/main/java/com/yahoo/vespa/model/container/search | |
parent | b7d75ef658fbe4a5157e667b09392f1e474945fe (diff) |
Add necessary config to ClusterConfig to avoid hidden relation via clusterId to QrSearchersConfig
Diffstat (limited to 'config-model/src/main/java/com/yahoo/vespa/model/container/search')
-rw-r--r-- | config-model/src/main/java/com/yahoo/vespa/model/container/search/searchchain/LocalProvider.java | 17 |
1 files changed, 1 insertions, 16 deletions
diff --git a/config-model/src/main/java/com/yahoo/vespa/model/container/search/searchchain/LocalProvider.java b/config-model/src/main/java/com/yahoo/vespa/model/container/search/searchchain/LocalProvider.java index da7dfdc7b84..554dacb39e3 100644 --- a/config-model/src/main/java/com/yahoo/vespa/model/container/search/searchchain/LocalProvider.java +++ b/config-model/src/main/java/com/yahoo/vespa/model/container/search/searchchain/LocalProvider.java @@ -17,7 +17,6 @@ import com.yahoo.vespa.model.search.SearchCluster; import java.util.ArrayList; import java.util.LinkedHashSet; import java.util.List; -import java.util.Objects; import java.util.Set; /** @@ -38,12 +37,7 @@ public class LocalProvider extends Provider implements @Override public void getConfig(ClusterConfig.Builder builder) { - Objects.requireNonNull(searchCluster, "Null search cluster!"); - builder.clusterId(searchCluster.getClusterIndex()); - builder.clusterName(searchCluster.getClusterName()); - - if (searchCluster.getVisibilityDelay() != null) - builder.cacheTimeout(convertVisibilityDelay(searchCluster.getVisibilityDelay())); + searchCluster.getConfig(builder); } @Override @@ -131,13 +125,4 @@ public class LocalProvider extends Provider implements searchCluster.getConfig(builder); } - // The semantics of visibility delay in search is deactivating caches if the - // delay is less than 1.0, in qrs the cache is deactivated if the delay is 0 - // (or less). 1.0 seems a little arbitrary, so just doing the conversion - // here instead of having two totally independent implementations having to - // follow each other down in the modules. - private static Double convertVisibilityDelay(Double visibilityDelay) { - return (visibilityDelay < 1.0d) ? 0.0d : visibilityDelay; - } - } |