Marcel Reutegger created OAK-442:
------------------------------------

             Summary: Concurrently adding nodes fails with CommitFailedException
                 Key: OAK-442
                 URL: https://issues.apache.org/jira/browse/OAK-442
             Project: Jackrabbit Oak
          Issue Type: Bug
          Components: jcr
    Affects Versions: 0.5
            Reporter: Marcel Reutegger


Concurrently adding nodes fails with CommitFailedException with a conflict on 
the node type property index.

oak-jcr currently does not retry commits. In some cases retries are not useful, 
e.g. if conflict markers were added by AnnotatingConflictHandler. However, in 
the case described above, the conflict is introduced by the property index 
commit hook and a commit will eventually succeed when retried often enough.

There's one problem though, the MicroKernel API only specifies a generic 
MicroKernelException. JavaDoc for MicroKerne.commit() does not contain too much 
detail about the conflicting case. It currently only mentions that the 
implementation *tries* to merge non-conflicting changes. I think we need to be 
more specific here, even if we have to say it's implementation specific. A 
client needs to know what it can expect. Is an implementation allowed to simply 
overwrite a conflict? Is it a requirement to detect a conflict and throw an 
exception (and what kind of exception)?

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

Reply via email to