[ 
https://issues.apache.org/jira/browse/LUCENE-4598?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13526726#comment-13526726
 ] 

Shai Erera commented on LUCENE-4598:
------------------------------------

I said that because I was bitten by it (when implemented 
ParallelTaxonomyArrays.initParents). The scenario is that you have a 
FixedBitSet over r.maxDoc(). You then get an iterator from it, by *global* 
docIDs. So it's very easy to pull a top-level IR and skip by these global 
docIDs.

If instead you need to pull it per-segment, you need to do some math in the 
code, handle the case where a segment is entirely irrelevant ... stuff like 
that. Basically, I would imagine that we'll duplicate the MultiFields version 
for D&PEnum?

When I thought about making this class per-segment, I was thinking about 
LUCENE-4600 -- i.e. if we do in-collection aggregation, that class only needs 
to iterate within a single segment, on local docIDs. No complications.
                
> Facet aggregation should work per segment
> -----------------------------------------
>
>                 Key: LUCENE-4598
>                 URL: https://issues.apache.org/jira/browse/LUCENE-4598
>             Project: Lucene - Core
>          Issue Type: Improvement
>          Components: modules/facet
>            Reporter: Michael McCandless
>
> Currently the facet module uses MultiFields.* to pull the D&PEnum in 
> PayloadIterator, to access the payloads that store the facet ords.
> It then makes heavy use of .advance and .getPayload to visit all docIDs in 
> the result set.
> I think we should get some speedup if we go segment by segment instead ...

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
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