On 7/13/2021 2:30 PM, Mike Drob wrote:
One option that I've thought about is if instead of inserting results into the cache directly, we pre-register a future in the cache, and then use that as a reference to the results. Multiple queries coming in parallel would all wait for the same result calculation instead of allocating large arrays each.

That's a really interesting idea.  Sounds like a very good optimization.

As always the devil is in the details ... properly handling all the possible corner cases.  I worry that it's going to be a harder problem to solve than we think it is ... but I am not going to let that stand in the way of making the attempt.

When I first dreamed up LFUCache, I didn't think I was going to be able to write it.  But I decided to make the attempt anyway, and I think it was Hoss that committed it -- this was before I was asked to join the project.  Even though it's been obsoleted by the Caffeine version, I really enjoyed working on it.

Thanks,
Shawn


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@solr.apache.org
For additional commands, e-mail: dev-h...@solr.apache.org

Reply via email to