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

Marcel Reutegger commented on OAK-8591:
---------------------------------------

Thanks for the review. Good point about {{getLatestValue()}}. It looks like 
this method is not affected by the issue because it will always call 
{{isValidRevision()}} with a non-null {{commitValue}}. The problematic code 
path is only executed when {{commitValue}} is {{null}}. The incorrect call of 
{{isValidRevision()}} on the commit root document will still happen, but 
because {{commitValue}} is non-null, {{context.getCommitValue()}} with the 
commit root document won't be called.

> Conflict exception on commit
> ----------------------------
>
>                 Key: OAK-8591
>                 URL: https://issues.apache.org/jira/browse/OAK-8591
>             Project: Jackrabbit Oak
>          Issue Type: Bug
>          Components: documentmk
>            Reporter: Marcel Reutegger
>            Assignee: Marcel Reutegger
>            Priority: Blocker
>             Fix For: 1.18.0, 1.10.5, 1.8.17
>
>
> Under some conditions it may happen that a commit to the DocumentStore fails 
> with a ConflictException even though there is no conflicting change. This 
> includes regular commits as well as branch commits.
> The actual problem is with NodeDocument.getNewestRevision(). This method is 
> used in Commit.checkConflicts() to find out when the most recent change 
> happened on a node and find conflicts. The returned value is incorrect and 
> may e.g. return null even though the node exists. This will then trigger the 
> ConflictException.



--
This message was sent by Atlassian Jira
(v8.3.2#803003)

Reply via email to