Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 359586 - Merge UML Association doesn't work
Summary: Merge UML Association doesn't work
Status: CLOSED FIXED
Alias: None
Product: EMFCompare
Classification: Modeling
Component: Core (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows XP
: P3 major (vote)
Target Milestone: ---   Edit
Assignee: EMF Compare CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-09-30 12:12 EDT by Vincent Lorenzo CLA
Modified: 2013-01-17 08:32 EST (History)
4 users (show)

See Also:


Attachments
This zip contains a model to reproduce easily the bug (1.51 KB, application/octet-stream)
2011-09-30 12:14 EDT, Vincent Lorenzo CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Vincent Lorenzo CLA 2011-09-30 12:12:51 EDT
steps to reproduce : 
	1/ Create a model with 2 classes and an association between these classes
	2/ Copy your uml file
	3/ Delete the association in one of the models
	4/ compare the 2 uml files : the merge action works fine when we delete the association, but not when we want create it in the 2nd file.
Comment 1 Vincent Lorenzo CLA 2011-09-30 12:14:14 EDT
Created attachment 204397 [details]
This zip contains a model to reproduce easily the bug

This zip contains a model to reproduce easily the bug decribed in the previous comment.
Comment 2 Laurent Goubet CLA 2012-03-06 05:52:24 EST
There is a dependency loop between the two differences "hidden" under the association change. EMF Compare cannot properly merge these and that is what ultimately causes the IllegalArgumentException that happens when trying to execute this merge operation.
Comment 3 Sébastien Gérard CLA 2012-03-14 10:37:45 EDT
Hi Laurent,

I did not understand your argument against the bug. For me in terms of usage it is a bug of UML compare/merge to nkow be able to merge an association from one model to another.
Can you explain in more detail what it is an issue?

thanks.
Comment 4 Cedric Brun CLA 2012-03-14 10:44:20 EDT
It is indeed a bug. Laurent's note is his analysis of the issue. To fix this we need to make sure we're able to handle cyclic dependencies during merging.
Comment 5 Sébastien Gérard CLA 2012-03-14 10:45:42 EDT
Ok thanks. But where does this cyclic dependency come from?
Comment 6 Cedric Brun CLA 2012-03-14 11:00:34 EDT
To merge (apply for instance) the Association instance the property has to be added too as the Association refers to the property instance. To add the property instance, this object having a reference to the Association, the association change needs to be applied too.
Comment 7 Laurent Goubet CLA 2012-06-04 04:40:57 EDT
This has been fixed along the way (probably through bug 379740) and we can no longer reproduce the issue on the two provided models.
Comment 8 Laurent Goubet CLA 2013-01-17 08:32:43 EST
batch-closing a bunch of "RESOLVED" bugs.