Class QueryPhaseResultConsumer

java.lang.Object
org.elasticsearch.action.search.QueryPhaseResultConsumer
All Implemented Interfaces:
Closeable, AutoCloseable, Releasable

public class QueryPhaseResultConsumer extends Object implements Releasable
A ArraySearchPhaseResults implementation that incrementally reduces aggregation results as shard results are consumed. This implementation adds the memory that it used to save and reduce the results of shard aggregations in the CircuitBreaker.REQUEST circuit breaker. Before any partial or final reduce, the memory needed to reduce the aggregations is estimated and a CircuitBreakingException is thrown if it exceeds the maximum memory allowed in this breaker.