[ 
https://issues.apache.org/jira/browse/JCR-3349?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Claus Köll updated JCR-3349:
----------------------------

    Status: Patch Available  (was: Open)
    
> The DatabaseJournal has Problems in XA Environment
> --------------------------------------------------
>
>                 Key: JCR-3349
>                 URL: https://issues.apache.org/jira/browse/JCR-3349
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: jackrabbit-core
>    Affects Versions: 2.4.2
>            Reporter: Claus Köll
>            Assignee: Claus Köll
>             Fix For: 2.4.3
>
>         Attachments: JCR-3349.patch
>
>
> In XA Environment it's possible that two different Threads are used for 
> prepare() and commit()
> The ConnectionHelper stores the Connection that is used in the 
> DatabaseJournal on a ThreadLocal on prepare()
> On commit() comes a different Thread so the previous used Connection is not 
> on the ThreadLocal
> This is the resulting Thread-Dump
> java.lang.IllegalStateException: not in batch mode
>       at 
> org.apache.jackrabbit.core.util.db.ConnectionHelper.endBatch(ConnectionHelper.java:256)
>       at 
> org.apache.jackrabbit.core.journal.DatabaseJournal.endBatch(DatabaseJournal.java:513)
>       at 
> org.apache.jackrabbit.core.journal.DatabaseJournal.doUnlock(DatabaseJournal.java:501)
>       at 
> org.apache.jackrabbit.core.journal.AbstractJournal.unlock(AbstractJournal.java:330)
>       at 
> org.apache.jackrabbit.core.journal.AppendRecord.update(AppendRecord.java:279)
>       at 
> org.apache.jackrabbit.core.cluster.ClusterNode$WorkspaceUpdateChannel.updateCommitted(ClusterNode.java:664)
>       at 
> org.apache.jackrabbit.core.state.SharedItemStateManager$Update.end(SharedItemStateManager.java:809)
>       at 
> org.apache.jackrabbit.core.state.XAItemStateManager.commit(XAItemStateManager.java:181)
>       at 
> org.apache.jackrabbit.core.TransactionContext.commit(TransactionContext.java:195)
>       at 
> org.apache.jackrabbit.core.XASessionImpl.commit(XASessionImpl.java:326)
>       at 
> org.apache.jackrabbit.jca.TransactionBoundXAResource.commit(TransactionBoundXAResource.java:49)

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


Reply via email to