BooleanQuery should not extract terms from FILTER clauses.
Here is a patch.
Commit 1673120 from Adrien Grand in branch 'dev/trunk'
[ https://svn.apache.org/r1673120 ]
LUCENE-6416: BooleanQuery.extractTerms now only extracts terms from scoring clauses.
Commit 1673122 from Adrien Grand in branch 'dev/branches/branch_5x'
[ https://svn.apache.org/r1673122 ]
Adrien Grand I don't express a concern, but would you mind to clarify the motivation?
We have two use-cases for extractTerms today: distributed IDF and highlighting and both of them only care about scoring clauses.
Also this way it is consistent with FilteredQuery which does not extract terms from the filter.
Bulk close for 5.2.0.