[ https://issues.apache.org/jira/browse/LUCENE-1089?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Michael McCandless updated LUCENE-1089: --------------------------------------- Attachment: LUCENE-1089.take3.patch Patch looks good; I made a few changes (attached take3): * Put back the minScore optimization in TopDocCollector.collect & FuzzyQuery, but, using reusableSD.score as the bar. This saves changing reusableSD & calling insertWithOverflow for every candidate. Then I put back TopFieldDocCollector.collect since it can't make that same optimization. * I implemented PriorityQueue.insert by calling insertWithOverflow (so we keep the tricky insert logic as single source). * I changed reusableSD in TopDocCollector to private (it was protected -- was there a reason?). * Made another small optimization to PriorityQueue that saves the if statement in top() (this was #2 in Nadav's additional suggestions). * Small javadoc fixes. > Add insertWithOverflow to PriorityQueue > --------------------------------------- > > Key: LUCENE-1089 > URL: https://issues.apache.org/jira/browse/LUCENE-1089 > Project: Lucene - Java > Issue Type: Improvement > Affects Versions: 2.3 > Reporter: Shai Erera > Assignee: Michael McCandless > Priority: Minor > Fix For: 2.3 > > Attachments: LUCENE-1089.take3.patch, PriorityQueue-2.patch, > PriorityQueue.patch > > > This feature proposes to add an insertWithOverflow to PriorityQueue so that > callers can reuse the objects that are being dropped off the queue. Also, it > changes heap to protected for easier extensibility of PQ -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]