lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Shai Erera (Commented) (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (LUCENE-3573) TaxonomyReader.refresh() is broken, replace its logic with reopen(), following IR.reopen pattern
Date Mon, 14 Nov 2011 16:47:52 GMT

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

Shai Erera commented on LUCENE-3573:
------------------------------------

My thinking is that today refresh() modifies the internal state, and does so in an optimized
manner (however I think we thought there might be concurrency issues with it). And people
(whoever they are) got used to it. And the TaxonomyReader does not imply in any way that it
is an index (i.e. we've been thinking about implementing the taxonomy as a serialized FST
maybe).

So in fact, let's not call it openIfChanged, because may not be meaningful. We can call it
reload() maybe (just to have a better name). Now the question is whether we want to trust
javadocs to note that the returned value may not be equals to the given one (ala the old IndexReader.reopen()),
or follow the same IR concept where reload() is static.

If we want to follow IR semantics fully, then option B is the right one. But can it be done
in an optimized manner? I bet we won't have any concurrency issues with it ...
                
> TaxonomyReader.refresh() is broken, replace its logic with reopen(), following IR.reopen
pattern
> ------------------------------------------------------------------------------------------------
>
>                 Key: LUCENE-3573
>                 URL: https://issues.apache.org/jira/browse/LUCENE-3573
>             Project: Lucene - Java
>          Issue Type: Bug
>          Components: modules/facet
>            Reporter: Doron Cohen
>            Assignee: Doron Cohen
>            Priority: Minor
>         Attachments: LUCENE-3573.patch
>
>
> When recreating the taxonomy index, TR's assumption that categories are only added does
not hold anymore.
> As result, calling TR.refresh() will be incorrect at best, but usually throw an AIOOBE.

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