Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 374882

Summary: Issue on control/uncontrol of model element with Savepoint
Product: [Modeling] EMF Reporter: Eike Stepper <stepper>
Component: cdo.coreAssignee: Eike Stepper <stepper>
Status: CLOSED FIXED QA Contact: Eike Stepper <stepper>
Severity: major    
Priority: P3    
Version: 4.1   
Target Milestone: ---   
Hardware: PC   
OS: Linux   
Whiteboard:

Description Eike Stepper CLA 2012-03-21 06:55:50 EDT
Cloned from: 374418: Issue on control/uncontrol of model element with Savepoint
https://bugs.eclipse.org/bugs/show_bug.cgi?id=374418

Build Identifier: 

With a metamodel generated in native with containment proxy to true :
1. Control a model element to a new resource
2. Set a savepoint
3. Commit
4. Uncontrol this model element to its original resource
2. Set a savepoint
3. Commit
1. Control again this model element to the new resource
2. Set a savepoint
3. Commit

I get the following exception on commit :

org.eclipse.emf.cdo.util.CommitException: Rollback in MEMStore: java.lang.IllegalStateException: Origin revision not found for CDORevisionDelta[Root@OID5:0v3 --> [CDOFeatureDelta[null, CONTAINER, resource=OID6, container=OID4, feature=-1]]]
	at org.eclipse.emf.cdo.internal.server.TransactionCommitContext.computeDirtyObject(TransactionCommitContext.java:959)
	at org.eclipse.emf.cdo.internal.server.TransactionCommitContext.computeDirtyObjects(TransactionCommitContext.java:937)
	at org.eclipse.emf.cdo.internal.server.TransactionCommitContext.write(TransactionCommitContext.java:455)
	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)
	at org.eclipse.emf.cdo.server.internal.net4j.protocol.CommitTransactionIndication.indicatingCommit(CommitTransactionIndication.java:244)
	at org.eclipse.emf.cdo.server.internal.net4j.protocol.CommitTransactionIndication.indicating(CommitTransactionIndication.java:92)
	at org.eclipse.emf.cdo.server.internal.net4j.protocol.CDOServerIndicationWithMonitoring.indicating(CDOServerIndicationWithMonitoring.java:109)
	at org.eclipse.net4j.signal.IndicationWithMonitoring.indicating(IndicationWithMonitoring.java:84)
	at org.eclipse.net4j.signal.IndicationWithResponse.doExtendedInput(IndicationWithResponse.java:90)

Reproducible: Always
Comment 1 Eike Stepper CLA 2012-03-21 07:43:20 EDT
commit b2f82eac6c3d9a487e419c3aecb5dad0178c14ae
Comment 2 Eike Stepper CLA 2012-09-21 07:17:43 EDT
Closing.