While reading "Lucene in Action 2nd edition" I came across the description of Filter
classes which are could be used for result filtering in Lucene. Lucene has a lot of filters repeating Query
classes. For example, NumericRangeQuery
and NumericRangeFilter
.
The book says that NRF
does exactly the same as NRQ
but without document scoring. Does this means that if I do not need scoring or sort documents by document field value I should prefer Filter
ing over Query
ing from performance point of view?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…