[
https://issues.apache.org/jira/browse/JCR-2866?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12988153#action_12988153
]
John Langley commented on JCR-2866:
-----------------------------------
Another similar question about applicability to different branches.
Will this fix be applied to the 2.1 branch? We're running 2.1.3 currently.
Thanks in advance for clarifications.
> Cluster: Node type register/unregister deadlock
> -----------------------------------------------
>
> Key: JCR-2866
> URL: https://issues.apache.org/jira/browse/JCR-2866
> Project: Jackrabbit Content Repository
> Issue Type: Bug
> Components: clustering
> Reporter: Thomas Mueller
> Assignee: Thomas Mueller
> Fix For: 2.2.2
>
> Attachments: jcr-2866-a.patch
>
>
> A deadlock can occur when two cluster nodes concurrently register or
> unregister node types.
> Reason:
> NodeTypeRegistry.registerNodeTypes is synchronized, and calls
> eventChannel.registered(ntDefs), which calls AbstractJournal.lockAndSync(),
> which tries to lock AbstractJournal.rwLock.
> On the other hand, AbstractJournal.sync() locks AbstractJournal.rwLock, then
> calls NodeTypeRecord.process, which calls
> NodeTypeRegistry.unregisterNodeTypes, which is also synchronized.
> Possible solutions: Either
> - NodeTypeRegistry doesn't synchronize on the object when calling a
> eventChannel method,
> - or NodeTypeRegistry locks AbstractJournal.rwLock before synchronizing.
> There might be other solutions.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.