> > where/how were you getting your SortedIntDocSet instances that you looked > at in the debugger? ... where you constructing them directly, or were they > the end product of some fq execution > and/or SolrIndexSearcher.getProcessedFilter() ?
Yes it is coming from SolrIndexSearcher.getProcessedFilter(). Here is the path of how the filter is constructed: KnnQParser.parse() -> KnnQParser.getFilterQuery() -> req.getSearcher().getProcessedFilter(null, filters); In SolrIndexSearcher.getProcessedFilter(), there is a special logic to process negative fq. What I observed is that for positive fqs, ProcessedFilter.filter is of SortedIntDocSet instance, but BitDocSet for negative fqs. Hope this helps. Yes I agree that fixing with hashCode & equals impls seems trivial, but it may be masking some bigger issue, also FixedBitSet.hashCode() could be slow if the bit set is very big. Thank you, Yue On Mon, Dec 8, 2025 at 6:32 PM Chris Hostetter <[email protected]> wrote: > > : why you see different behavior for SortedIntDocSet vs. BitDocSet > : > : > : This is the part I'm confused about as well, I'm not sure if the native > : implementation has any differences for those 2 classes, but this is what > I > : see when I run through the debugger. > > where/how were you getting your SortedIntDocSet instances that you looked > at in the debugger? ... where you constructing them directly, or were they > the end product of some fq execution > and/or SolrIndexSearcher.getProcessedFilter() ? > > My suspicion is that all of the SortedIntDocSet instances that gave you > consistent hashCode() results were actually the *same* instance: the > DocSet.empty() singleton. > > In any case -- I create a jira with a test case patch that demonstrates at > least one version of this problem... > > https://issues.apache.org/jira/browse/SOLR-18020 > > ...but i don't have firm handle on why the "positive" vs "negative" fq > usage should behave differently. > > I feel like understanding that is pretty damn important before diving in > too much on "fixing" the DocSet hashCode & equals impls -- adding correct > impls of those methods may fix the symptoms, but the failure discrepency > worries me .... makes me think some other bug or innefficiency is hiding > in here. > > > -Hoss > http://www.lucidworks.com/ > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > >
