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 "Chetan Mehrotra (JIRA)" <ji...@apache.org> on 2013/08/05 14:07:48 UTC

[jira] [Commented] (OAK-939) Removing modified node in different session leads to conflict

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

Chetan Mehrotra commented on OAK-939:
-------------------------------------

Testcase added with rev 1510440
                
> Removing modified node in different session leads to conflict
> -------------------------------------------------------------
>
>                 Key: OAK-939
>                 URL: https://issues.apache.org/jira/browse/OAK-939
>             Project: Jackrabbit Oak
>          Issue Type: Sub-task
>          Components: jcr
>    Affects Versions: 0.8
>            Reporter: Chetan Mehrotra
>         Attachments: OAK-939.patch
>
>
> If a node is modified and remove in different session then it leads to conflict failed exception. Following testcase passes on JR2 and fails on Oak
> {code:java}
>     @Test
>     public void removeNodeInDifferentSession() throws RepositoryException {
>         Session s3 = getRepository().login(new SimpleCredentials("admin", "admin".toCharArray()));
>         Session s2 = getRepository().login(new SimpleCredentials("admin","admin".toCharArray()));
>         s2.getNode(TEST_PATH).setProperty("foo","bar");
>         s2.save();
>         s3.getNode(TEST_PATH).remove();
>         s3.save();
>     }
> {code}
> The testcase would pass if session refresh interval is set to zero

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