You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jackrabbit.apache.org by "Claus Köll (JIRA)" <ji...@apache.org> on 2013/10/21 08:14:42 UTC
[jira] [Comment Edited] (JCR-3682) If we get a unexpected exception
from the jdbc driver it's possible create a unreleased VersioningLock
[ https://issues.apache.org/jira/browse/JCR-3682?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13800394#comment-13800394 ]
Claus Köll edited comment on JCR-3682 at 10/21/13 6:13 AM:
-----------------------------------------------------------
You are right but I think it's not so easy because the rollback (not the unlock) will be done in TransactionContext.
The rollback will be done if a TransactionException will be thrown and this will only be thrown if one layer below a ItemStateException occurs and so on ...
I did not want to change much code on much layers ...
was (Author: c_koell):
You are right but I think it's not so easy because the rollback (not the unlock) will be done in TransactionContext.
The rollback will be done if a TransactionException will be thrown and this will only be thrown if one layer below a ItemStateException occurs.
I did not want to change much code on much layers ...
> If we get a unexpected exception from the jdbc driver it's possible create a unreleased VersioningLock
> ------------------------------------------------------------------------------------------------------
>
> Key: JCR-3682
> URL: https://issues.apache.org/jira/browse/JCR-3682
> Project: Jackrabbit Content Repository
> Issue Type: Bug
> Components: jackrabbit-core, transactions
> Affects Versions: 2.6.4, 2.7.1
> Reporter: Claus Köll
> Assignee: Claus Köll
> Fix For: 2.6.5, 2.7.2
>
> Attachments: JCR-3682.patch
>
>
> If we get a unexpected exception from the jdbc driver the VersioningLock from the versionMgr.getXAResourceEnd() XAResource will never be released so the repository is locked forever. We should catch every Exception in BundleDbPersistenceManager.readBundle() to prevent that situation.
> Following Stacktrace shows the problem ...
> Caused by: java.lang.ArrayIndexOutOfBoundsException
> at oracle.jdbc.driver.T4CSocketInputStreamWrapper.readLongMSB(T4CSocketInputStreamWrapper.java:201)
> at oracle.jdbc.driver.T4CMAREngine.buffer2Value(T4CMAREngine.java:2374)
> at oracle.jdbc.driver.T4CMAREngine.unmarshalUB4(T4CMAREngine.java:1310)
> at oracle.jdbc.driver.T4CTTIoer.unmarshal(T4CTTIoer.java:257)
> at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:447)
> at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:192)
> at oracle.jdbc.driver.T4C8TTILob.read(T4C8TTILob.java:146)
> at oracle.jdbc.driver.T4CConnection.getBytes(T4CConnection.java:2392)
> at oracle.sql.BLOB.getBytes(BLOB.java:348)
> at oracle.jdbc.driver.OracleBlobInputStream.needBytes(OracleBlobInputStream.java:181)
> at oracle.jdbc.driver.OracleBufferedStream.readInternal(OracleBufferedStream.java:174)
> at oracle.jdbc.driver.OracleBufferedStream.read(OracleBufferedStream.java:143)
> at org.apache.commons.io.input.ProxyInputStream.read(ProxyInputStream.java:75)
> at org.apache.commons.io.input.CountingInputStream.read(CountingInputStream.java:74)
> at java.io.DataInputStream.readFully(DataInputStream.java:189)
> at java.io.DataInputStream.readFully(DataInputStream.java:163)
> at org.apache.jackrabbit.core.persistence.util.BundleReader.readBytes(BundleReader.java:669)
> at org.apache.jackrabbit.core.persistence.util.BundleReader.readName(BundleReader.java:520)
> at org.apache.jackrabbit.core.persistence.util.BundleReader.readQName(BundleReader.java:469)
> at org.apache.jackrabbit.core.persistence.util.BundleReader.readBundleNew(BundleReader.java:194)
> at org.apache.jackrabbit.core.persistence.util.BundleReader.readBundle(BundleReader.java:145)
> at org.apache.jackrabbit.core.persistence.util.BundleBinding.readBundle(BundleBinding.java:152)
> at org.apache.jackrabbit.core.persistence.pool.BundleDbPersistenceManager.readBundle(BundleDbPersistenceManager.java:927)
> at org.apache.jackrabbit.core.persistence.pool.BundleDbPersistenceManager.loadBundle(BundleDbPersistenceManager.java:889)
> at org.apache.jackrabbit.core.persistence.bundle.AbstractBundlePersistenceManager.getBundleCacheMiss(AbstractBundlePersistenceManager.java:766)
> at org.apache.jackrabbit.core.persistence.bundle.AbstractBundlePersistenceManager.getBundle(AbstractBundlePersistenceManager.java:749)
> at org.apache.jackrabbit.core.persistence.bundle.AbstractBundlePersistenceManager.storeInternal(AbstractBundlePersistenceManager.java:633)
> at org.apache.jackrabbit.core.persistence.bundle.AbstractBundlePersistenceManager.store(AbstractBundlePersistenceManager.java:590)
> at org.apache.jackrabbit.core.persistence.pool.BundleDbPersistenceManager.store(BundleDbPersistenceManager.java:482)
> at org.apache.jackrabbit.core.state.SharedItemStateManager$Update.end(SharedItemStateManager.java:788)
> 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)
> at com.ibm.ejs.j2c.XATransactionWrapper.commit(XATransactionWrapper.java:490)
--
This message was sent by Atlassian JIRA
(v6.1#6144)