Searching a frozen index

edit

Frozen indices are throttled in order to limit memory consumptions per node. The number of concurrently loaded frozen indices per node is limited by the number of threads in the search_throttled threadpool, which is 1 by default. Search requests will not be executed against frozen indices by default, even if a frozen index is named explicitly. This is to prevent accidental slowdowns by targeting a frozen index by mistake. To include frozen indices a search request must be executed with the query parameter ignore_throttled=false.

GET /twitter/_search?q=user:kimchy&ignore_throttled=false

While frozen indices are slow to search, they can be pre-filtered efficiently. The request parameter pre_filter_shard_size specifies a threshold that, when exceeded, will enforce a round-trip to pre-filter search shards that cannot possibly match. This filter phase can limit the number of shards significantly. For instance, if a date range filter is applied, then all indices (frozen or unfrozen) that do not contain documents within the date range can be skipped efficiently. The default value for pre_filter_shard_size is 128 but it’s recommended to set it to 1 when searching frozen indices. There is no significant overhead associated with this pre-filter phase.