Community
Participate
Working Groups
Created attachment 251365 [details] libraryAndConsumerProjects scenario: use capella and import the attach projects libraryAndConsumerProjects * open library session * open fragment System * fragment SystemAnalysis * save model.aird * unfragment SystemAnalysis * fragment SystemAnalysis =>le LRC is not clean * unfragment SystemAnalysis * save model.aird * fragment SystemAnalysis => the model.aird is not modified The issue comes from the LocalResourceCollector that is badly updated at semantic resource modification.
The methods LocalResourceCollector.LocalInverseCrossReferencer.remove/add are overloaded to create bi directional links between used/using resources. When LocalInverseCrossReferencer.remove(EObject eObject, EReference eReference, EObject crossReferencedEObject), crossReferencedEObject.eResource() can be null if the resource has been unloaded. This leads to let the link between resources when it should be removed. A proposal is to maintain a map of EObject to its resource to retreive the resource that was containing the EObject.
Gerrit change https://git.eclipse.org/r/148637 was merged to [master]. Commit: http://git.eclipse.org/c/sirius/org.eclipse.sirius.git/commit/?id=8e17f58534dc50ad784dc901a240a4723c9904d9
See work done in Bug 550371, the ResourceLocator has been integrated in the session semantic cross referencer. This issue is still existing but some symptoms might be different. We made a modification in order to have better results even if the internal state of the IResourceLocator is not valid: the resulting resources are filtered to remove resources with no resource set.