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

Thomas Mueller commented on OAK-464:
------------------------------------

I would rather solve the problem in oak-core than adding more and more methods 
to the MicroKernel API so that you don't have to. In this case, it seems to me 
a problem of RootImpl.rebase() and not a deficiency of the MicroKernel API.

If MicroKernel.rebase is just a convenience method for

{code}
public String rebase(String branchRevision, String newBaseRevision) {
    String revision = branch(newBaseRevision);
    for (String jsop : getBranchCommitsUntil(branchRevision)) {
        revision = commit("/", jsop, revision, null);
    }
    return revision;
}
{code}

Then I suggest to implement the method in oak-core. The missing piece (why it 
can't be implemented in oak-core right now) is that the getJournal call doesn't 
return branch commits, but this is something that could be easily added in the 
MicroKernel specification.

                
> RootImpl.rebase() doesn't handle move operations correctly
> ----------------------------------------------------------
>
>                 Key: OAK-464
>                 URL: https://issues.apache.org/jira/browse/OAK-464
>             Project: Jackrabbit Oak
>          Issue Type: Bug
>            Reporter: Michael Dürig
>
> Doing {{RootImpl.rebase()}} causes moves to be changed to remove followed by 
> add. Which causes moves of large sub trees to become very expensive.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to