elasticsearch/elasticsearch — pull request #5588 by martijnvg (2014-03-28 07:24:11+00:00)
Title: Percolator doesn't reduce CircuitBreaker stats in every case.

In the case a filter / query is in a percolator query that uses FieldData, after percolating when the in-memory index gets cleared up the circuit breaker stats don't get reduced. Resulting in a discrepancy between what fielddata and the circuit breaker are reporting.

The fix makes sure that the circuit breaker stats gets reduced even for a segment no shard id can be found, which is the case for the in-memory index the percolator is used to percolate documents.