Bug 432982 - MappingsUpdater should not manage DSemanticDecorator with detached target
Summary: MappingsUpdater should not manage DSemanticDecorator with detached target
Status: CLOSED FIXED
Alias: None
Product: Sirius
Classification: Modeling
Component: Diagram (show other bugs)
Version: 1.0.0   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 2.0.0   Edit
Assignee: Esteban DUGUEPEROUX CLA
QA Contact:
URL:
Whiteboard:
Keywords: performance, triaged
Depends on:
Blocks:
 
Reported: 2014-04-17 03:57 EDT by Alex Lagarde CLA
Modified: 2014-10-27 06:52 EDT (History)
4 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Alex Lagarde CLA 2014-04-17 03:57:09 EDT
DiagramMappingsManagerImpl.iterate(MappingsListVisitor, DragAndDropTarget) method evaluates the semantic candidate expressions for sub-elements (nodes, brodered nodes...) even for DNodeContainer that are about to be deleted (their target is null or target.eResource() is null). This is done during the MappingsUpdater.updateMappings(DragAndDropTarget) called by the DDiagramSynchronizer.refreshOpertaion().

This can lead to interpreter issues and cost performances for no reason.
Comment 1 Maxime Porhel CLA 2014-04-18 10:14:38 EDT
Alex could you add a reproduction case ?
Comment 2 Maxime Porhel CLA 2014-07-07 10:52:39 EDT
Correction will have to be done on DNodeContainer, DNodeList, and DNode
Comment 3 Pierre-Charles David CLA 2014-08-06 11:49:59 EDT
See also bug 440032, which will probably involve large refactorings of DiagramMappingsManagerImpl.
Comment 4 Esteban DUGUEPEROUX CLA 2014-09-25 08:47:13 EDT
The issue comes from DDiagramSynchroniser which call MappingsUpdater even for container whose target is detached. Consequently when interpreted expression should be evaluated during refresh, the IInterpreter cannot be found on the detached target.

See https://git.eclipse.org/r/33886 for a fix.
Comment 5 Esteban DUGUEPEROUX CLA 2014-10-14 08:47:43 EDT
b40976e5b30359689069fa636769007eec85a003 integrate the fix.
Comment 6 Pierre-Charles David CLA 2014-10-27 06:52:25 EDT
Available in Sirius 2.0.0.