Bug 241385 - Graphical Differencing for GMF modellers
Summary: Graphical Differencing for GMF modellers
Status: CLOSED FIXED
Alias: None
Product: EMFCompare
Classification: Modeling
Component: Core (show other bugs)
Version: unspecified   Edit
Hardware: All All
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: EMF Compare CLA
QA Contact:
URL:
Whiteboard:
Keywords: contributed
Depends on:
Blocks:
 
Reported: 2008-07-18 08:30 EDT by Tobias Jaehnel CLA
Modified: 2011-08-18 04:06 EDT (History)
8 users (show)

See Also:


Attachments
Current source code (18.68 KB, application/x-zip-compressed)
2009-01-28 17:10 EST, Tobias Jaehnel CLA
no flags Details
GMF Compare V0.2 (18.68 KB, application/x-zip-compressed)
2009-01-29 16:54 EST, Tobias Jaehnel CLA
cedric.brun: iplog+
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Tobias Jaehnel CLA 2008-07-18 08:30:14 EDT
This Enhancement request is intended for all discussions on the Graphical Differencing extension to EMF Compare.
Comment 1 Cedric Brun CLA 2008-07-18 08:40:27 EDT
This bug is meant to track discussions started on the EMFT mailling list :
http://dev.eclipse.org/mhonarc/lists/emft-dev/msg00326.html
Comment 2 Tobias Jaehnel CLA 2008-07-21 09:17:02 EDT
The SourceForge Project has been approved and created.
- Current sources have been imported into CVS.
- Team Project Set is available here:
  http://gmfdiff.sourceforge.net/gmfdiff-pserver.psf
Comment 3 Tobias Jaehnel CLA 2008-07-21 11:04:41 EDT
I would like to hear your suggestions to the following point:

GMF diagrams are usually split into two files: The semantic model and the notation model. What's the expected behaviour of the user, when he wants to see graphical differences?
Probably right-clicking on file and selecting "Compare to...".

Problem 1:
Which file to click on? Semantic model, oder Notation model?

Problem 2:
When both files are in a CVS/SVN repository (or even local history), how can I find the semantic model, corresponding to the notation model? The revisions of both files not neccessarily have to be the same.
As a result there might be revisions of the semantic model the user can't even see when comparing the notation model.

Problem 3:
On the other hand, using the semantic model file to get into the compare dialog also has some disadvantages:
- a notation model has to be initialized and there could be more than one applicable modeller
- When creating a diagram from a semantic model, the shapes get arragend automatically

Any ideas?
Could we probably disregard some of these problems?
Comment 4 Tobias Jaehnel CLA 2008-07-31 10:04:31 EDT
I want to provide you with an update on my current work:
The last days I did some refactoring
- The EMF-Compare MergeService now helps in the merge process of left and right model
- Semantic and notation models are handled independently. This helps when models are in separate files.
- Since the diff result on semantic model and on notation model vary extremely, I decided to only performed the diff on the semantic model. Had to do some tricks to map the merged Notation and Semantic models together.

It is now possible to:
- Compare ECore Diagrams
- Compare virtually any GMF models (By now you have to add the extensions to the plugin.xml) - I'm sure there are still some problems
- Compare diagrams with semantic and notation model in one file or in separate files

Please note: single-file diagrams should work always. When semantic and notation model are in separate files, you can only compare local ones. It not yet possible to have them in a repository because the semantic model cannot be loaded automatically. -> See previous post.

Toby
Comment 5 Laurent Goubet CLA 2008-07-31 10:36:24 EDT
Hi Tobias,

Your problem 2 will indeed be a blocker as EMF Compare does not yet fetches the revision of linked models. Let's consider you have a semantic Model A and a notation model A'. You then right click on A' and select compare with => latest from repository. A' will then be compared with its remote counter part, but both will resolve their dependencies to the _local_ A : the remote A' will *not* fetch the remote A to resolve its proxies.

This is a problem we need to find a solution for as per bug 199877.

As for problems 1 and 3 ... well I think comparing the semantic model should not call for a graphical comparison. The user may need to have the classical "tree" comparison EMF Compare provides even though he has defined diagrams on it. Thus I think the graphical comparison should only be called upon when comparing the diagram files.

Cédric might have more input on the latter.
Comment 6 Tobias Jaehnel CLA 2008-07-31 11:37:16 EDT
Thanks Laurent.

My current implementation works, as suggested, by clicking on the notation model file. Did you have a look?

I saw that you plan to fix the problem with referenced models from the repository by version 1.0, so I will not go deeper into this then.
Comment 7 Tobias Jaehnel CLA 2008-08-04 13:07:24 EDT
I've done several bugfixes, code cleanup and beautifying.
Briefly tested and fixed Ecore Diagrams (.ecore_diagram, .ecorediag) and UML activity diagrams (.umlact)

I'm going to pause development now and continue writing my thesis.
Comment 8 Cedric Brun CLA 2008-08-05 03:55:15 EDT
Ok Tobias, In the meantime I'll dig further in the code and see If I can provides inputs or enhancements.

Thanks for your hard work !
Comment 9 Cedric Brun CLA 2009-01-28 08:01:18 EST
Hi Tobias,

sorry for coming back about his subject so late, but the time is ticking too fast !

If we want this code to get integrated in Eclipse Galileo we need to quickly move, the "contribution questionnaire" deadline is January 31st !!

Please follow the steps described here and contribute the code as a zip:

http://wiki.eclipse.org/TM_and_RSE_FAQ#How_do_I_submit_a_contribution_beyond_a_simple_bug_fix.3F

So that I can submit the questionnaire before saturday.

Comment 10 Tobias Jaehnel CLA 2009-01-28 17:10:45 EST
Created attachment 124100 [details]
Current source code
Comment 11 Tobias Jaehnel CLA 2009-01-28 17:18:55 EST
Hi,

I attached the current sources to this bug - hopefully everything is right.

There is one problem I just mentioned:
The code works perfectly with the EMF Compare version that is shipped with Eclipse Ganymede.
But it seems that in the current version from CVS the AddModelElement has no getRightElement method anymore, instead there is a getLeftElement. The other way round in RemoveModelElement.

Did you change the diff direction?

Tobias
Comment 12 Laurent Goubet CLA 2009-01-28 18:15:58 EST
Hi Tobias,

Yes, in the process of resolving bug #232277 , we reverted back left and right panes as they are in "classic" comparisons (we did have them the wrong way around all along). We currently are in the process of stabilizing the API in order to be all set for the Galileo M6 API freeze, and for the 1.0 release as well (that is the version we will have our stable API in).

I expect the API changes to be almost done (at least, existing API shouldn't change anymore, yet we will surely open more classes). The one last "big" break will come with the removal of all "Remote*" changes that will be replaced by their local counterparts, with an "isRemote()" method which will return a simple boolean.

Sorry for the extra trouble.
Comment 13 Cedric Brun CLA 2009-01-29 13:22:03 EST
Hi Tobias,

I think we still need the "employer consent" if an employer is involved in this and the legal statement.

points 2 and 4 stated here :http://wiki.eclipse.org/TM_and_RSE_FAQ#How_do_I_submit_a_contribution_beyond_a_simple_bug_fix.3F
Comment 14 Tobias Jaehnel CLA 2009-01-29 16:54:48 EST
Created attachment 124211 [details]
GMF Compare V0.2

Working with current CVS of EMF-Compare now.
Comment 15 Tobias Jaehnel CLA 2009-01-29 16:57:12 EST
Legal Message: I, Tobias Jähnel, declare that I developed attached code from scratch, without referencing any 3rd party materials except material licensed under the EPL.
I certify that I am the copyright owner and authorize this contribution. 
Comment 16 Tobias Jaehnel CLA 2009-05-24 15:04:16 EDT
Finally I got my Master Thesis about this topic online.
I'm always very busy. ;)

If you're interested, have a look: http://mt.jonmedia.net

Comment 17 Cedric Brun CLA 2009-05-26 09:35:59 EDT
Congratulation and thanks for the link Tobias !


Comment 18 Cedric Brun CLA 2009-05-27 11:41:34 EDT
Everything has been cleared for the CQ.
Comment 19 Cedric Brun CLA 2010-05-26 11:03:55 EDT
cleaning up the IP log by removing the iplog+ on the bug but adding it on the patches. 
sorry for the mail bombinb involved here :/
Comment 20 Eddie Galvez CLA 2011-04-25 14:58:31 EDT
has this been contributed to release builds, or it is only in source? I fail to find it when looking at any build release of EMF Compare
Comment 21 Laurent Goubet CLA 2011-08-18 04:06:52 EDT
Closing our "resolved" and "verified" bugs.