org.eclipse.emf.cdo.util
Class ContainmentCycleException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by org.eclipse.emf.cdo.util.CommitException
              extended by org.eclipse.emf.cdo.util.ConcurrentAccessException
                  extended by org.eclipse.emf.cdo.util.ContainmentCycleException
All Implemented Interfaces:
Serializable

public class ContainmentCycleException
extends ConcurrentAccessException

A concurrent access exception that indicates an attempt of the local transaction to introduce a containment cycle. A containment cycle is an effect of a network race condition between two transactions that commit changes to possibly disjunct sets of objects. As a result the overall tree structure of the model would be destroyed in a way that the tree root would no longer be reachable from objects involved in the containment cycle. Commits that attempt to introduce containment cycles are detected by the repository and canceled. Note that locking all involved dirty objects does not properly address the problem because the involved container objects may not be dirty.

It's usually possible and adequate to rollback the transaction, replay the model modifications and commit the transaction again (optimistic strategy). Pessimistic locks on the dirty objects can not safely avoid the problem; you must expect this exception to occur.

Since:
4.2
See Also:
Serialized Form
No Extend
This interface is not intended to be extended by clients.
No Instantiate
This class is not intended to be instantiated by clients.

Constructor Summary
ContainmentCycleException(String message)
           
 
Method Summary
 
Methods inherited from class org.eclipse.emf.cdo.util.CommitException
isLocal, wrap
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ContainmentCycleException

public ContainmentCycleException(String message)


Copyright (c) 2011, 2012 Eike Stepper (Berlin, Germany) and others.