[
https://issues.apache.org/jira/browse/LUCENE-1476?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12653752#action_12653752
]
Michael McCandless commented on LUCENE-1476:
--------------------------------------------
bq. But, SegmentReader needs random access to the bits (DocIdSet only provides
an iterator)?
Although IndexReader.isDeleted exposes a random-access API to deleted docs, I
think it may be overkill.
Ie, in most (all?) uses of deleted docs throughout Lucene core/contrib, a
simple iterator (DocIdSet) would in fact suffice.
EG in SegmentTermDocs iteration we are always checking deletedDocs by ascending
docID. It might be a performance gain (pure speculation) if we used an
iterator API, because we could hold "nextDelDocID" and only advance that
(skipTo) when the term's docID has moved past it. It's just like an "AND NOT
X" clause.
Similarly, norms, which also now expose a random-access API, should be fine
with an iterator type API as well.
This may also imply better VM behavior, since we don't actually require
norms/deletions to be fully memory resident.
This would be a biggish change, and it's not clear whether/when we should
explore it, but I wanted to get the idea out there.
Marvin, in KS/Lucy are you using random-access or iterator to access
deletedDocs & norms?
> BitVector implement DocIdSet
> ----------------------------
>
> Key: LUCENE-1476
> URL: https://issues.apache.org/jira/browse/LUCENE-1476
> Project: Lucene - Java
> Issue Type: Improvement
> Components: Index
> Affects Versions: 2.4
> Reporter: Jason Rutherglen
> Priority: Trivial
> Attachments: LUCENE-1476.patch
>
> Original Estimate: 12h
> Remaining Estimate: 12h
>
> BitVector can implement DocIdSet. This is for making
> SegmentReader.deletedDocs pluggable.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]