[ 
https://issues.apache.org/jira/browse/SOLR-2906?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Shawn Heisey updated SOLR-2906:
-------------------------------

    Attachment: SOLR-2906.patch

Updated patch.  One of the bugs I had to fix was in the least/most items 
methods, so that I added new items to the TreeSet before removing old ones, 
because the one it just added might have the same hitcount as entries already 
present.  Without checking the new entry, I couldn't know which entry was the 
right one to remove.

This change reverts it to a remove then add when the hitCounts are different in 
the right direction.  When they are equal, it still does the add before the 
remove.  By reducing the size of the set before adding a new member whenever 
possible, there is a possibility it can go faster.

                
> Implement LFU Cache
> -------------------
>
>                 Key: SOLR-2906
>                 URL: https://issues.apache.org/jira/browse/SOLR-2906
>             Project: Solr
>          Issue Type: Sub-task
>          Components: search
>    Affects Versions: 3.4
>            Reporter: Shawn Heisey
>            Priority: Minor
>         Attachments: ConcurrentLFUCache.java, LFUCache.java, SOLR-2906.patch, 
> SOLR-2906.patch, TestLFUCache.java
>
>
> Implement an LFU (Least Frequently Used) cache as the first step towards a 
> full ARC cache

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to