Class LRUStatsCache

  • All Implemented Interfaces:
    PluginInfoInitialized

    public class LRUStatsCache
    extends ExactStatsCache
    Unlike ExactStatsCache this implementation preserves term stats across queries in a set of LRU caches, and based on surface features of a query it determines the need to send additional RPC-s. As a result the additional RPC-s are needed much less frequently.

    Query terms and their stats are maintained in a set of maps. At the query front-end there will be as many maps as there are shards, each maintaining the respective shard statistics. At each shard server there is a single map that is updated with the global statistics on every request.