[CDO/db4o store] Multi session/transaction problems [message #990060] |
Mon, 10 December 2012 16:48 |
ben ben Messages: 28 Registered: June 2012 |
Junior Member |
|
|
I'm trying to switch from Hibernate Store to db4o store.
I have 2 client applications that have their own Session/Transaction.
Transaction is never closed until the client isn't.
Assume Client1 = C1 & Client2 = C2.
C1 makes changes to its transaction
C1 commits
OK
C2 makes changes to its transaction
C2 commits
NOK !
It get this server side :
java.util.ConcurrentModificationException: Attempt by Transaction[4:1] to modify historical revision: OID2:0v13
at org.eclipse.emf.cdo.internal.server.TransactionCommitContext.isContainerLocked(TransactionCommitContext.java:802)
at org.eclipse.emf.cdo.internal.server.TransactionCommitContext.lockObjects(TransactionCommitContext.java:735)
at org.eclipse.emf.cdo.internal.server.TransactionCommitContext.write(TransactionCommitContext.java:434)
at org.eclipse.emf.cdo.spi.server.InternalCommitContext$1.runLoop(InternalCommitContext.java:42)
at org.eclipse.emf.cdo.spi.server.InternalCommitContext$1.runLoop(InternalCommitContext.java:1)
at org.eclipse.net4j.util.om.monitor.ProgressDistributor.run(ProgressDistributor.java:96)
Using debug in TransactionCommitContext.isContainerLocked(), I found that resource revision version is not incremented on C2 when C1 commits its changes.
Must I use PassiveUpdate mode ? I hope no cause it does not work in my app ...
Thanks !
UPDATE :
Same problem with DBStore
java.lang.IllegalStateException: Can only retrieve current version 14 for OID2 - version requested was CDORevisionDelta[CDOResource@OID2:0v13 --> [CDOFeatureDelta[contents, LIST, list=[CDOFeatureDelta[contents, ADD, value=oid1, index=105]]]]]
at org.eclipse.emf.cdo.server.internal.db.DBStoreAccessor.readRevisionByVersion(DBStoreAccessor.java:283)
at org.eclipse.emf.cdo.internal.server.Repository.loadRevisionByVersion(Repository.java:519)
at org.eclipse.emf.cdo.internal.common.revision.CDORevisionManagerImpl.getRevisionByVersion(CDORevisionManagerImpl.java:236)
at org.eclipse.emf.cdo.internal.server.TransactionCommitContext.isContainerLocked(TransactionCommitContext.java:798)
[Updated on: Mon, 10 December 2012 17:25] Report message to a moderator
|
|
|
Re: [CDO/db4o store] Multi session/transaction problems [message #990142 is a reply to message #990060] |
Tue, 11 December 2012 06:42 |
|
Hi Ben,
Please wait with that switch until we hear from Vik (the developer of the DB4O store) whether he plans to maintain it
properly. I won't! Of course you could decide to maintain it yourself or become a CDO committer ;-)
Cheers
/Eike
----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Am 10.12.2012 17:48, schrieb ben ben:
> I'm trying to switch from Hibernate Store to db4o store.
>
> I have 2 client applications that have their own Session/Transaction.
> Transaction is never closed until the client isn't.
>
> Assume Client1 = C1 & Client2 = C2.
>
> C1 makes changes to its transaction
> C1 commits
> OK
> C2 makes changes to its transaction
> C2 commits
> NOK !
>
> It get this server side :
>
> java.util.ConcurrentModificationException: Attempt by Transaction[4:1] to modify historical revision: OID2:0v13
> at org.eclipse.emf.cdo.internal.server.TransactionCommitContext.isContainerLocked(TransactionCommitContext.java:802)
> at org.eclipse.emf.cdo.internal.server.TransactionCommitContext.lockObjects(TransactionCommitContext.java:735)
> at org.eclipse.emf.cdo.internal.server.TransactionCommitContext.write(TransactionCommitContext.java:434)
> at org.eclipse.emf.cdo.spi.server.InternalCommitContext$1.runLoop(InternalCommitContext.java:42)
> at org.eclipse.emf.cdo.spi.server.InternalCommitContext$1.runLoop(InternalCommitContext.java:1)
> at org.eclipse.net4j.util.om.monitor.ProgressDistributor.run(ProgressDistributor.java:96)
>
>
> Using debug in TransactionCommitContext.isContainerLocked(), I found that resource revision version is not incremented
> on C2 when C1 commit it's changes.
>
> Must I use PassiveUpdate mode ? I hope no cause it does not work in my app ...
>
> Thanks !
Cheers
/Eike
----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
|
|
|
|
|
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.08928 seconds