Collaborative mode FAQ
This section groups all questions related to the Collaborative mode integration and API.
1. "Cannot modify ResourceSet without a write transaction" issues
These issues often occur when you provide your own EditingDomain through an EditingDomainFactory instead of using the default Sirius Editing Domain.
The provided EditingDomain should extend fr.obeo.dsl.viewpoint.collab.api.editingdomain.CDOEditingDomain
or at least override the following method as bellow:
@Override
protected TransactionChangeRecorder createChangeRecorder(ResourceSet rset) {
return new CDOTransactionChangeRecorder(this, rset);
}
2. Why my representations not opened by a representation editor get locked when a user removes a semantic element from outside representation editor?
When a user removes a semantic element from a representation editor (e.g. diagram editor), only the representations opened by an editor concerned by this remove get locked. If you have, for example, a contextual action contributed in the model explorer to delete semantic elements and this action use a DeleteCommand
or EcoreUtil.delete()
, then it is normal that all concerned representations get locked because such mechanism removes dangling references. Hence, they impact even not opened representations. To avoid such issue and keep the same behavior as with a representation editor, RemoveCommand
should be used instead.