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

Marcel Reutegger commented on OAK-3712:
---------------------------------------

Introduced a {{NodeDocumentSweeper}}: http://svn.apache.org/r1788218

It is responsible for removing uncommitted changes up to the current head 
revision of a given clusterId. In contrast to the initial implementation on the 
github branch, this implementation does not rewrite merged branch commits. 
Branch commits in Oak 1.8 have a marker (OAK-5869) and their commit root 
entries will not be garbage collected. It does however clean up unmerged branch 
commits created by earlier version of Oak.

The intended use for this class is in different areas:
- There will be an oak-run command that allows to sweep the nodes collection 
for a given clusterId as a preparation for an upgrade. This will reduce startup 
time when an Oak instance is upgraded to 1.8. The basic idea here is to stop 
one Oak instance in a cluster running e.g. 1.6. Run the sweeper for the shut 
down cluster node without updating the format version to 1.8 yet. Stop the 
other cluster nodes, run unlockUpgrade to 1.8 and start the first Oak instance 
again. Then continue upgrading the remaining cluster nodes to 1.8.
- Run the sweeper on startup if necessary. A sweep run is necessary when the 
sweep revision for a clusterId is older than the head revision component for 
the same clusterId.
- Run the sweeper on demand, when commits by the DocumentNodeStore fail to roll 
back.
- Run the sweeper as part of the LastRev recovery for another cluster node.

Right now, the sweeper is not yet used in any of the above areas. This will be 
done in a next step.

> Clean up old and uncommitted changes
> ------------------------------------
>
>                 Key: OAK-3712
>                 URL: https://issues.apache.org/jira/browse/OAK-3712
>             Project: Jackrabbit Oak
>          Issue Type: New Feature
>          Components: core, documentmk
>            Reporter: Marcel Reutegger
>            Assignee: Marcel Reutegger
>             Fix For: 1.8
>
>
> Clean up old and uncommitted changes in the main document. This issue is 
> related to OAK-2392, which is specifically about changes on binary properties 
> and effect on blob GC.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to