For simulated queries count also buffered updates.

This commit is contained in:
Andrzej Bialecki 2018-09-28 20:23:02 +02:00
parent 9481c1f623
commit 918b11c7ce
1 changed files with 4 additions and 0 deletions

View File

@ -1617,6 +1617,10 @@ public class SimClusterStateProvider implements ClusterStateProvider {
ReplicaInfo ri = getReplicaInfo(r);
Number numDocs = (Number)ri.getVariable("SEARCHER.searcher.numDocs", 0L);
count.addAndGet(numDocs.longValue());
AtomicLong bufferedUpdates = (AtomicLong)sliceProperties.get(collection).get(s.getName()).get(BUFFERED_UPDATES);
if (bufferedUpdates != null) {
count.addAndGet(bufferedUpdates.get());
}
}
QueryResponse rsp = new QueryResponse();
NamedList<Object> values = new NamedList<>();