lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Uwe Schindler (Commented) (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (LUCENE-3630) MultiReader and ParallelReader accidently override doOpenIfChanged(boolean readOnly) with doOpenIfChanged(boolean doClone)
Date Sat, 10 Dec 2011 09:43:39 GMT

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

Uwe Schindler commented on LUCENE-3630:
---------------------------------------

Only MultiReader has this problem, ParallelReader used another method name for the internal
reopen. I will make the internal implementation private for both classes (they were protected
because of the above override issue) and rename it to doReopen().

The same on trunk, where some relicts of those method signatures are still protected. But
the bug does not occur here.
                
> MultiReader and ParallelReader accidently override doOpenIfChanged(boolean readOnly)
with doOpenIfChanged(boolean doClone)
> --------------------------------------------------------------------------------------------------------------------------
>
>                 Key: LUCENE-3630
>                 URL: https://issues.apache.org/jira/browse/LUCENE-3630
>             Project: Lucene - Java
>          Issue Type: Bug
>          Components: core/index
>    Affects Versions: 3.5
>            Reporter: Uwe Schindler
>             Fix For: 3.6
>
>
> I found this during adding deprecations for RW access in LUCENE-3606:
> the base class defines doOpenIfChanged(boolean readOnly), but MultiReader and ParallelReader
"override" this method with a signature doOpenIfChanged(doClone) and missing @Override. This
makes consumers calling IR.openIfChanged(boolean readOnly) do the wrong thing. Instead they
should get UOE like for the other unimplemented doOpenIfChanged methods in MR and PR.
> Easy fix is to rename and hide this internal "reopen" method, like DirectoryReader,...

--
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


Mime
View raw message