[ 
https://issues.apache.org/jira/browse/LUCENE-2895?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Shai Erera updated LUCENE-2895:
-------------------------------

    Attachment: LUCENE-2895.patch

MockRandom randomly set termsIndexDivisor. Changed it to set it only if it's 
not already -1, in which case we know someone specifically asked not to load 
the terms index (such as the test).

Patch includes the fix in MockRandomCodec and removes MockRandom from the set 
of illegal codecs.

> MockRandomCodec loads termsIndex even if termsIndexDivisor is set to -1
> -----------------------------------------------------------------------
>
>                 Key: LUCENE-2895
>                 URL: https://issues.apache.org/jira/browse/LUCENE-2895
>             Project: Lucene - Java
>          Issue Type: Bug
>          Components: Codecs
>            Reporter: Shai Erera
>             Fix For: 4.0
>
>         Attachments: LUCENE-2895.patch
>
>
> When working on LUCENE-2891 (on trunk), I found out that if MockRandomCodec 
> is used, then setting IWC.readerTermsIndexDivisor to -1 allows seeking e.g., 
> termDocs, when it shouldn't. Other Codecs fail to seek, as expected by the 
> test. We need to find out why MockRandomCodec does not fail as expected.
> To verify that, run "ant test-core -Dtestcase=TestIndexWriterReader 
> -Dtestmethod=testNoTermsIndex -Dtests.codec=MockRandom", but comment out the 
> line which adds MockRandom to the list of illegal codecs in the test.

-- 
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: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to