jackrabbit-oak-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Dürig (JIRA) <j...@apache.org>
Subject [jira] [Commented] (OAK-2307) Provide API to create Tree from NodeState
Date Mon, 08 Dec 2014 08:46:12 GMT

    [ https://issues.apache.org/jira/browse/OAK-2307?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14237625#comment-14237625

Michael Dürig commented on OAK-2307:

I'm reluctant about his additional method until we have a clear picture about its intended
semantics. With {{ImmutableTree}} it is IMO flawed as:

    ImmutableTree parent = new ImmutableTree(EMPTY_NODE);
    ImmutableTree child = new ImmutableTree(parent, "child", EMPTY_NODE);

IMO {{Tree}} instance should just decorate the underlying {{NodeState}} instance with additional

For the use case in {{LuceneIndexEditor}} the [else | https://github.com/apache/jackrabbit-oak/blob/trunk/oak-lucene/src/main/java/org/apache/jackrabbit/oak/plugins/index/lucene/LuceneIndexEditor.java#L156]
branch should probably just change to 

    current = parent.current.getChild(name);

> Provide API to create Tree from NodeState
> -----------------------------------------
>                 Key: OAK-2307
>                 URL: https://issues.apache.org/jira/browse/OAK-2307
>             Project: Jackrabbit Oak
>          Issue Type: Improvement
>          Components: core
>            Reporter: Chetan Mehrotra
>            Assignee: Michael Dürig
>            Priority: Minor
>             Fix For: 1.2
> Oak Core should provide a way to construct {{Tree}} instances from {{NodeState}}. As
noted in [1] its not possible to export the tree related packages due to current design issue
we need to provide way for users to create Tree from NodeState
> [1] http://markmail.org/thread/o5yzdsm3pb234h7m

This message was sent by Atlassian JIRA

View raw message