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

Stefan Guggisberg commented on OAK-1203:
----------------------------------------

+1 for the patch

BTW: isn't this already possible with the existing MicroKernel API
(albeit not necesseraly as efficently)?

i.e.
{code:java}
// assuming rev1 denotes the current branch revision 
// and rev0 denotes an ancestor branch revision
        
// get reverse diff
String reverseDiff = mk.diff(rev1, rev0, null, -1);
// commit reverse diff
String rev2 = mk.commit("", reverseDiff, rev1, null);
// the trees at revisions rev0 and rev2 are now identical
{code}

> Reset branch to previous commit
> -------------------------------
>
>                 Key: OAK-1203
>                 URL: https://issues.apache.org/jira/browse/OAK-1203
>             Project: Jackrabbit Oak
>          Issue Type: New Feature
>          Components: mk, mongomk
>            Reporter: Marcel Reutegger
>            Assignee: Marcel Reutegger
>         Attachments: OAK-1203.patch
>
>
> To resolve OAK-1056 and OAK-1202 there must be a way to reset a branch to a 
> previous commit. 



--
This message was sent by Atlassian JIRA
(v6.1#6144)

Reply via email to