You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-issues@jackrabbit.apache.org by "Marcel Reutegger (JIRA)" <ji...@apache.org> on 2015/01/21 10:33:34 UTC

[jira] [Resolved] (OAK-2421) Clean up orphaned branches

     [ https://issues.apache.org/jira/browse/OAK-2421?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Marcel Reutegger resolved OAK-2421.
-----------------------------------
       Resolution: Fixed
    Fix Version/s: 1.1.6

Orphaned unmerged branches are now detected when created with the NodeStore API. An unmerged branch becomes orphaned when the DocumentNodeStoreBuilder and associated DocumentNodeStoreBranch is garbage collected. The implementation tracks this with a weak reference to the DocumentNodeStoreBranch. Once the DocumentNodeStoreBranch is weakly reachable and appended to the reference queue, the branch is considered orphaned and cleaned up by the background operations thread in DocumentNodeStore.

The background thread is not able to remove all persisted changes related to the branch. It will only remove the branch commits and any collision markers from the root document. The actual changes persisted with branch commits are not removed because it would require a scan on the underlying data. This step must be done by the full scale revision GC (OAK-1981). Some cleanup is already done when a document is analyzed for splitting. The background split now also removes changes from orphaned branch commits.

Done in trunk: http://svn.apache.org/r1653463

> Clean up orphaned branches
> --------------------------
>
>                 Key: OAK-2421
>                 URL: https://issues.apache.org/jira/browse/OAK-2421
>             Project: Jackrabbit Oak
>          Issue Type: Sub-task
>          Components: core, mongomk
>    Affects Versions: 1.0
>            Reporter: Marcel Reutegger
>            Assignee: Marcel Reutegger
>             Fix For: 1.1.6
>
>
> This is a sub-task of OAK-1981 to clean up orphaned branches.
> Branch commits may not get merged because of conflicts and are currently not garbage collected. OAK-1926 cleans up the branch commit information on restart on the root document, but it does not remove the changes on the affected documents.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)