Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 328456 - Using XML/EJBJAR/WEBAPP discoverer from popup menu leads to wrong model opening
Summary: Using XML/EJBJAR/WEBAPP discoverer from popup menu leads to wrong model opening
Status: CLOSED FIXED
Alias: None
Product: MoDisco
Classification: Modeling
Component: Technologies (show other bugs)
Version: 0.9.0   Edit
Hardware: PC Windows XP
: P2 normal (vote)
Target Milestone: 0.9.0 M4   Edit
Assignee: Fabien Giquel CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-10-22 07:37 EDT by Fabien Giquel CLA
Modified: 2011-05-23 08:49 EDT (History)
3 users (show)

See Also:
fabien.giquel: indigo+


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Fabien Giquel CLA 2010-10-22 07:37:28 EDT
It is a general pb with a category of discoverers which does not serialize the resulting models : 
- Generic XML Model Discoverer
- EjbJar XML Model Discoverer
- WebApp XML Discoverer

When called from the popup menu on a file, the discovery itself is ok but the model openening in modisco browser reinstantiate the model from the "XX.xml" file which leads to call another EMF Resource Factory -> the model finally opened does not conform to the mm asked.

This pb does not occurs with other discoverers which produces a .xmi result file.

This side effect is not visible in 0.8 since only 'Generic XML discoverer' was included.
Comment 1 Fabien Giquel CLA 2010-10-22 07:41:40 EDT
This problem has to be resolved within the MoDisco Discovery Framework refactoring task which is currently in progress.
Comment 2 Fabien Giquel CLA 2010-11-15 09:58:06 EST
a reminder : not sure of the reason why a wrong Resource Factory is used by the Modisco Browser : the code used to force the good factory in global Resource.FActory registry. It used to work.


Whatever the problem is, the good solution is to give the instanciated resource directly to the MoDisco browser -> MoDisco Discovery Framework
refactoring task.
Comment 3 Fabien Giquel CLA 2010-12-14 06:13:42 EST
Completing last comment :

"the code used to force the good factory in global Resource.FActory registry. It used to work."

The problem comes now from MoDisco Model browser which evolves with some asynchronous model opening (to avoid UI freez i think) -> the workaround "force the good factory in global Resource.FActory registry" does not work anymore.

For instance : taking a "web.webapp25" file, and launching a "discover generic xml" results in opening a webapp25 model rather than a xml model.
Comment 4 Fabien Giquel CLA 2010-12-14 08:24:50 EST
Fixed the three discvoerers (XML, JEE webapp and ejbjar discoverer) for sending directly the result Resource to the MoDisco browser (rev 3629).
Comment 5 Hugo Bruneliere CLA 2011-01-11 05:06:25 EST
Bug fixed.