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

Jukka Zitting commented on OAK-638:
-----------------------------------

My initial idea when I proposed the branch concept was for the MicroKernel to 
internally do something like what the SegmentMK now does, i.e. a new branch 
would initially live only in local memory and would automatically get flushed 
to the underlying storage engine when it grows beyond some 
implementation-specific limit.

Thus the expectation in oak-core has been that MK.branch() would be a very 
efficient call that requires no network or disk IO until later if the branch 
grows too large.

We can implement similar logic in oak-core to push out the branch() call as 
much as possible, but there we hit a similar problem as with the node cache - 
the MK implementation has much better information about the relative costs of 
different storage accesses and can thus make better decisions about how to best 
handle branches.
                
> Avoid branch/merge for small commits
> ------------------------------------
>
>                 Key: OAK-638
>                 URL: https://issues.apache.org/jira/browse/OAK-638
>             Project: Jackrabbit Oak
>          Issue Type: Improvement
>          Components: core
>            Reporter: Marcel Reutegger
>            Priority: Minor
>
> The branch/merge features on the MicroKernel were initially introduced to 
> stage changes of large commits. Currently oak-core creates a branch even for 
> small changes like updating a property. I think this introduces quite some 
> overhead for scenarios with highly concurrent updates. E.g. think of a 
> twitter like application or a forum with comments. Well, basically user 
> generated content. These update tend to be rather small (couple of nodes) but 
> frequent and concurrent.
> Right now oak-core always does:
> - MK.branch()
> - MK.commit() to branch
> - MK.merge()
> For small commits, it ideally should do:
> - MK.commit() to trunk

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