You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Robert Muir (Updated) (JIRA)" <ji...@apache.org> on 2011/11/17 04:34:51 UTC
[jira] [Updated] (LUCENE-3580) Most 4.0 PostingsReaders don't obey
DISI contract
[ https://issues.apache.org/jira/browse/LUCENE-3580?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Robert Muir updated LUCENE-3580:
--------------------------------
Attachment: LUCENE-3580.patch
patch with a test, and fixes for SimpleText and PreFlex, but i didn't fix any of the other postings readers.
> Most 4.0 PostingsReaders don't obey DISI contract
> -------------------------------------------------
>
> Key: LUCENE-3580
> URL: https://issues.apache.org/jira/browse/LUCENE-3580
> Project: Lucene - Java
> Issue Type: Bug
> Affects Versions: 4.0
> Reporter: Robert Muir
> Attachments: LUCENE-3580.patch
>
>
> While trying to do some refactoring, I noticed funky things going on with some codecs.
> One problem is that DocIdSetIterator says the following:
> {noformat}
> Returns the following:
> * <ul>
> * <li>-1 or {@link #NO_MORE_DOCS} if {@link #nextDoc()} or
> * {@link #advance(int)} were not called yet.
> {noformat}
> But most 4.0 Docs/DocsAndPositionsEnums don't actually do this (e.g. return 0). instead we
> are relying on Scorers to 'cover' for them, which is inconsistent. Some scorers actually rely
> upon this behavior, for example look at ReqExclScorer.toNonExcluded(), it calls docId() on the
> excluded part before it calls nextDoc()
> So we need to either fix these enums, change these enums to not extend DocIdSetIterator (and redefine
> what the actual contract should be for these enums), change DocIdSetIterator, or something else.
> Fixing the enums to return -1 here when they are uninitialized kinda sucks for the ones summing up
> document deltas...
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org