Bug 535673

Summary: Model inferrer instantiates XbaseEvaluator instances
Product: [Modeling] Viatra Reporter: Zoltan Ujhelyi <zoltan.ujhelyi>
Component: QueryAssignee: Zoltan Ujhelyi <zoltan.ujhelyi>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: 2.0.0   
Target Milestone: 2.0.1   
Hardware: Macintosh   
OS: Mac OS X   
See Also: https://git.eclipse.org/r/124263
https://git.eclipse.org/c/viatra/org.eclipse.viatra.git/commit/?id=7a64739b423bca2f7c33ac39b38595f81351440f
https://git.eclipse.org/r/125403
https://git.eclipse.org/c/viatra/org.eclipse.viatra.git/commit/?id=da4f61dc66a85267d9285cf239490615b81fc2fb
Whiteboard:

Description Zoltan Ujhelyi CLA 2018-06-08 03:51:24 EDT
I have seen that the method `BodyCodeGenerator#acceptExpressionEvaluator` instantiates an instance XBaseEvaluator. This is plainly unnecessary here, as the Xbase generator is used there; on the other hand, it can be expensive as it requires (1) locating the Java project metadata for the current object, and (2) initializing a URLClassLoader for that project. We should remove this call here, and replace its usages with the corresponding static method calls.
Comment 1 Eclipse Genie CLA 2018-06-08 10:51:41 EDT
New Gerrit change created: https://git.eclipse.org/r/124263
Comment 3 Eclipse Genie CLA 2018-07-03 10:47:53 EDT
New Gerrit change created: https://git.eclipse.org/r/125403
Comment 5 Zoltan Ujhelyi CLA 2018-07-03 16:12:58 EDT
Fixed in master and backported to 2.0-maintenance.