On Mon, Jun 23, 2014 at 3:56 PM, Ravikumar Govindarajan <ravikumar.govindara...@gmail.com> wrote: > Yes, we can get the top-50 docs finally. I am not denying that. > > I will probably re-phrase my question. Apologize if I am not clear > > How do we ensure global sort-order during search across all segments of the > index, when using ESTC+SMP that works only at per-segment level?
At indexing time, SortingMergePolicy serializes the sort order that has been used into the merged segment. At search time, the collector checks for this information: either the sort order matches and ESTC will early-terminate collection on this segment, or the sort order is not specified in the segment or doesn't match, and all documents that match the query will be collected as usual. This makes sure that all matches that might be competitive are collected. -- Adrien --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org For additional commands, e-mail: java-user-h...@lucene.apache.org