I found this, which intends to explore the usage of RoaringDocIdSet for solr: https://issues.apache.org/jira/browse/SOLR-9008 This suggests Lucene’s filter cache already uses it, or did at one point: https://issues.apache.org/jira/browse/LUCENE-6077
I was playing with id set implementations earlier this year for https://issues.apache.org/jira/browse/LUCENE-7211. I know I tried a SparseFixedBitSet there, and I think that I observed that RoaringDocIdSet existed and tried that too, but I apparently didn’t write anything down. My vague recollection is that I couldn’t use it for my use case, due to the in-order insertion requirement. On 12/1/16, 8:10 AM, "Shawn Heisey" <apa...@elyograg.org> wrote: On 12/1/2016 8:16 AM, Dorian Hoxha wrote: > @Shawn > Any idea why the cache doesn't use roaring bitsets ? I had to look that up to even know what it was. Apparently Lucene does have an implementation of that, a class called RoaringDocIdSet. It was incorporated into the source code in October 2014 with this issue: https://issues.apache.org/jira/browse/LUCENE-5983 As for the reason that it wasn't used for the filterCache, I think that's because the filterCache existed LONG before that bitset implementation was available, and when things work well (which describes the filterCache), devs try not to mess with them too much. I have mentioned the idea on a recently-filed issue regarding bitset memory efficiency: https://issues.apache.org/jira/browse/SOLR-9764 Thanks, Shawn