ISSUE:
Currently, for a local modeling project, the aird resource uses UUIds(org.eclipse.sirius.business.internal.resource.AirDResourceImpl.useUUIDs() returns true) for its contained elements.
In the persisted aird file, it results of of xmiid attribute for every xml elements.
Some other application based on Sirius may serialize the aird resource differently for example in a database. In that case, AirDResourceImpl is not used but a resource which is not a XMIResourceImpl.
The consequence is when the application converts AirdResource from an implementation that not have xmiids to the AirDResourceImpl one, the xmiid are recreated and are different from the one used at the last AirDResourceImpl instanciation.
The consequence is that the aird file which has passed through the mechanism of convertion becomes different while no contained elements has changed.
That is problematic for workflow that considere aird changes. Typically for file versioning application such as git.
PROPOSAL:
The proposal is to have a technical id attribute for every object in the aird resource. This technical id would be used as uuid and, as any other attributes, would be persisted whatever the aird resource implementation is used.
As a consequence, the meta-model of objects persisted in aird resource has to be changed. It covers:
* sirius meta model (viewpoint.ecore, diagram.ecore, tree.ecore, table.ecore, sequence.ecore). Actually, only viewpoint.ecore would be changed as it defined the super class of all other classes in other meta-models.
* viewpoint description metamodel (viewpoint.ecore)
* GMF meta-model (annotation.ecore)
Comment 1Pierre-Charles David
2018-06-26 03:10:54 EDT
*** Bug 531410 has been marked as a duplicate of this bug. ***
The above gerrit has been abandonned in favor of an equivalent change (https://git.polarsys.org/r/#/c/6521/) directly in Capella which want to keep the old uid as new uri fragment for the DRepresentation elements. Sirius will continue to keep the same urifragment when used outside of Capella: the old xmi:id of DRepresentation is kept as new uid and the previous uid is dropped by the automatic migration (the GMF diagram element reference and the DRepresentation.repPath are updated).