lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael McCandless <>
Subject Re: Optimization of memory usage in PriorityQueue
Date Mon, 22 Jun 2009 09:29:25 GMT
On Mon, Jun 22, 2009 at 3:25 AM, Shai Erera<> wrote:

> Or ... we can do nothing, and say that one can write his own Collector, and
> use Sun's PQ (or any other), if one has a case like "I need 10K results, but
> I don't know how many are there, and specifically I want to optimize for the
> case of 1 result".


I think Lucene's current PQ is optimized for the [very] common case,
and if someone would like to eg swap to Sun's PQ impl, the custom
Collector API is the best route.  (And, I'd love to hear back on how
the performance compares!  If Sun has a faster PQ than Lucene, we
should fix that ;) ).

Though, are Lucene's core collectors reusable?  If you did really want
say 100K results out of each search (very unusual), it'd be nice to
not have to throw away the Collector/PQ each time.


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message