aboutsummaryrefslogtreecommitdiffstats
path: root/config-model/src/main/java/com/yahoo/vespa/model/content/ContentSearchCluster.java
diff options
context:
space:
mode:
authorHenning Baldersheim <balder@yahoo-inc.com>2024-03-13 23:22:34 +0100
committerHenning Baldersheim <balder@yahoo-inc.com>2024-03-14 19:55:00 +0100
commita544670e6f9f9146cc9514d86a440d05d76be28b (patch)
tree142870b150bba9659b3653aae2e20fb04494e794 /config-model/src/main/java/com/yahoo/vespa/model/content/ContentSearchCluster.java
parent3c1d192192f903b0dffc81b2f3503830a705f0eb (diff)
Avoid dependency of IndexedSearchCluster
Diffstat (limited to 'config-model/src/main/java/com/yahoo/vespa/model/content/ContentSearchCluster.java')
-rw-r--r--config-model/src/main/java/com/yahoo/vespa/model/content/ContentSearchCluster.java6
1 files changed, 2 insertions, 4 deletions
diff --git a/config-model/src/main/java/com/yahoo/vespa/model/content/ContentSearchCluster.java b/config-model/src/main/java/com/yahoo/vespa/model/content/ContentSearchCluster.java
index e2fe660cbe9..469901bb542 100644
--- a/config-model/src/main/java/com/yahoo/vespa/model/content/ContentSearchCluster.java
+++ b/config-model/src/main/java/com/yahoo/vespa/model/content/ContentSearchCluster.java
@@ -229,9 +229,8 @@ public class ContentSearchCluster extends TreeConfigProducer<AnyConfigProducer>
*/
public Boolean isStreaming() {
if (indexedCluster == null) return false;
- boolean hasStreaming = indexedCluster.schemas().values().stream().anyMatch(schema -> schema.getIndexMode() == SchemaInfo.IndexMode.STREAMING);
- boolean hasIndexed = indexedCluster.schemas().values().stream().anyMatch(schema -> schema.getIndexMode() == SchemaInfo.IndexMode.INDEX);
- if (hasIndexed == hasStreaming) return null;
+ boolean hasStreaming = indexedCluster.hasStreaming();
+ if (indexedCluster.hasIndexed() == hasStreaming) return null;
return hasStreaming;
}
@@ -404,7 +403,6 @@ public class ContentSearchCluster extends TreeConfigProducer<AnyConfigProducer>
getIndexed().getConfig(builder);
}
}
- public Map<String, SearchCluster> getClusters() { return clusters; }
public IndexedSearchCluster getIndexed() { return indexedCluster; }
public boolean hasIndexedCluster() { return indexedCluster != null; }
public IndexingDocproc getIndexingDocproc() { return indexingDocproc; }