| Summary: | EGL servlet needs model file in servlet directory | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | [Modeling] Epsilon | Reporter: | Ivo(sh) Musil <ivo> | ||||||||||
| Component: | Core | Assignee: | Dimitris Kolovos <dkolovos> | ||||||||||
| Status: | CLOSED FIXED | QA Contact: | |||||||||||
| Severity: | enhancement | ||||||||||||
| Priority: | P3 | CC: | ivo, louis | ||||||||||
| Version: | unspecified | ||||||||||||
| Target Milestone: | --- | ||||||||||||
| Hardware: | PC | ||||||||||||
| OS: | Linux | ||||||||||||
| See Also: | https://bugs.eclipse.org/bugs/show_bug.cgi?id=341481 | ||||||||||||
| Whiteboard: | |||||||||||||
| Attachments: |
|
||||||||||||
Created attachment 182266 [details]
Proposed patch to org.eclipse.epsilon.egl.servlet.ModelManager
Added another method signature for loadModel() expanded with boolean parameter (filesAreServletRelative, default value true).
Created attachment 182267 [details]
Correction of patch
CC-ed myself in case bug#341481 has fixed this. Created attachment 193351 [details] Patch to ModelManager after bug#241481 Hi Louis your change of EmfModel#load(StringProperties, String) in bug#341481 really solved my problem in EGL. I have only small enhancement to your code (method convertVirtualPathToAbsoluteFileURI in org.eclipse.epsilon.egl.servlet.ModelManager), which is able to load model or metamodel not only thru relative path (to web application root) but to absolute path too. Patch attached above. Thanks. Hi Ivo, Great -- I'm glad the other bug fix helped. I'll speak with Dimitris about what we need to do to integrate your patch. Cheers, Louis. Eclipse doesn't seem to be able to parse this patch (looks incomplete). Could you please attach a complete version so that I can have a look at it? Created attachment 194338 [details] Patch to ModelManager after bug#241481 (Eclipse format) Sorry Dimitros ... in previsous version I used unix commandline patch, new attachment is generated directly from Eclipse. Many thanks for the patch! I've merged it into the main branch and committed the changes to the SVN. |
Method loadModel in class org.eclipse.epsilon.egl.servlet.ModelManager used to loading model into EGL-based servlet can't get absolute path (at least on Linux platform). If you try loadModel("file:///absolute_path_to_model/abc.xyz",....) you get exception to unable load the model. Proposed solution follow ...