Hello,
Bryan Hunt and I just moved to a version of CDO from Head about two days
ago and that resolved a great many of our problems, including the two
previously posted SQLExceptions. (Thank you, Eike, for the
recommendation.)
Our model is a tree structure and the leaf nodes have a non-containment
reference to objects in another CDO model. This is working well under the
new code, except when I try to have two leaf nodes point to the same
object in the other CDO model. In that case, I get a “Duplicate ID” error
message (exception included below). I looked at the CDO source code, but
didn't see any obvious way around this limitation. Is there a way to
allow a CDO model to support duplicate non-containment references to
another CDO model? If not, should there be?
Here is the exception:
java.lang.IllegalStateException: Duplicate ID: CDOResource@OID10
at
org.eclipse.emf.internal.cdo.CDOViewImpl.registerObject(CDOViewImpl.java:738)
at
org.eclipse.emf.internal.cdo.CDOViewImpl.registerProxyResource(CDOViewImpl.java:717)
at
org.eclipse.emf.cdo.eresource.impl.CDOResourceFactoryImpl.createResource(CDOResourceFactoryImpl.java:70)
at
org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.createResource(ResourceSetImpl.java:425)
at
org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.demandCreateResource(ResourceSetImpl.java:239)
at
org.eclipse.emf.ecore.resource.impl.ResourceSetImpl.getResource(ResourceSetImpl.java:391)
at
org.eclipse.emf.internal.cdo.CDOViewImpl.getResource(CDOViewImpl.java:340)
at
org.eclipse.emf.internal.cdo.CDOViewImpl.getResource(CDOViewImpl.java:330)
Thanks in advance for your help!
Sincerely,
Stephen McCants