summaryrefslogtreecommitdiffstats
path: root/container-search/src/main/java/com/yahoo/search/dispatch/searchcluster/SearchCluster.java
diff options
context:
space:
mode:
authorJon Bratseth <bratseth@gmail.com>2021-06-15 17:18:08 +0200
committerJon Bratseth <bratseth@gmail.com>2021-06-15 17:18:08 +0200
commit2885c7c5b0d6e657ae33b8c1c8fd93030fa55226 (patch)
tree6e8ee9f0ac27db135b3a7c2fd29e4d5b1e6d8dd6 /container-search/src/main/java/com/yahoo/search/dispatch/searchcluster/SearchCluster.java
parentf986f75c5bb3f587bb39b290b78f335e24641e03 (diff)
Gc unused config options: min-group-coverage and max nodes per group
Diffstat (limited to 'container-search/src/main/java/com/yahoo/search/dispatch/searchcluster/SearchCluster.java')
-rw-r--r--container-search/src/main/java/com/yahoo/search/dispatch/searchcluster/SearchCluster.java5
1 files changed, 2 insertions, 3 deletions
diff --git a/container-search/src/main/java/com/yahoo/search/dispatch/searchcluster/SearchCluster.java b/container-search/src/main/java/com/yahoo/search/dispatch/searchcluster/SearchCluster.java
index 159a42676ec..9ae25518969 100644
--- a/container-search/src/main/java/com/yahoo/search/dispatch/searchcluster/SearchCluster.java
+++ b/container-search/src/main/java/com/yahoo/search/dispatch/searchcluster/SearchCluster.java
@@ -368,7 +368,7 @@ public class SearchCluster implements NodeManager<Node> {
*/
public boolean isPartialGroupCoverageSufficient(List<Node> nodes) {
if (orderedGroups().size() == 1)
- return nodes.size() >= wantedGroupSize() - dispatchConfig.maxNodesDownPerGroup();
+ return true;
long activeDocuments = nodes.stream().mapToLong(Node::getActiveDocuments).sum();
return isGroupCoverageSufficient(activeDocuments, medianDocumentsPerGroup());
}
@@ -378,7 +378,6 @@ public class SearchCluster implements NodeManager<Node> {
boolean changed = group.isFullCoverageStatusChanged(fullCoverage);
if (changed || (!fullCoverage && System.currentTimeMillis() > nextLogTime)) {
nextLogTime = System.currentTimeMillis() + 30 * 1000;
- int requiredNodes = group.nodes().size() - dispatchConfig.maxNodesDownPerGroup();
if (fullCoverage) {
log.info("Cluster " + clusterId + ": " + group + " has full coverage. " +
"Active documents: " + group.getActiveDocuments() + "/" + medianDocuments + ", " +
@@ -391,7 +390,7 @@ public class SearchCluster implements NodeManager<Node> {
}
log.warning("Cluster " + clusterId + ": " + group + " has reduced coverage: " +
"Active documents: " + group.getActiveDocuments() + "/" + medianDocuments + ", " +
- "working nodes: " + group.workingNodes() + "/" + group.nodes().size() + " required " + requiredNodes +
+ "working nodes: " + group.workingNodes() + "/" + group.nodes().size() +
", unresponsive nodes: " + (unresponsive.toString().isEmpty() ? " none" : unresponsive));
}
}