[BUG] IndicesQueryCache$CachingWeightWrapper#count should delegate to internal weight #10060
Labels
bug
Something isn't working
good first issue
Good for newcomers
Search
Search query, autocomplete ...etc
Describe the bug
Currently, IndicesQueryCache$CachingWeightWrapper#count does not delegate to internal weight object and keeps returning -1 from the Weight#count implementation. Due to this leaf counting cannot be done even when it is supported by Weight implementations like PointRangeQuery#createWeight
Expected behavior
Instrumenting the code for FiltersAggregator and observing with and without the change:
Without this change:
With the change:
Additional context
Instrumentation Code
Code change:
The text was updated successfully, but these errors were encountered: