You look at the hits you got back, and save the docID of the very last hit, and use that on the follow-on search to get the "next page". This is how searchAfter works ... but you need to ensure you use the same searcher for follow-on requests; otherwise the docIDs are not comparable. E.g. use SearcherLifetimeManager.
Mike McCandless http://blog.mikemccandless.com On Tue, Feb 18, 2014 at 11:14 AM, saisantoshi <saisantosh...@gmail.com> wrote: > The above works fine but how do I get the state of *last docID*. Also, there > will be multiple users accessing this and we need to maintain the integrity > of last docID. Can we know the last docID from the collector collect call? > > Thanks, > Ranjith. > > > > -- > View this message in context: > http://lucene.472066.n3.nabble.com/Collector-is-collecting-more-than-the-specified-hits-tp4117329p4118048.html > Sent from the Lucene - Java Users mailing list archive at Nabble.com. > > --------------------------------------------------------------------- > To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org > For additional commands, e-mail: java-user-h...@lucene.apache.org > --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscr...@lucene.apache.org For additional commands, e-mail: java-user-h...@lucene.apache.org