Towards Scalable Validation of Low-Code System Models: Mapping EVL to VIATRA Patterns
•
0 likes•199 views
Presented at the LowCode Workshop 2021 at MODELS 2021 by Benedek Horváth. Authors are Qurat ul ain Ali, Benedek Horváth, Dimitris Kolovos, Konstantinos Barmpis and Ákos Horváth.
1 of 16
Download to read offline
More Related Content
Towards Scalable Validation of Low-Code System Models: Mapping EVL to VIATRA Patterns
1. Towards Scalable Validation of Low-Code System Models:
Mapping EVL to VIATRA Patterns
Qurat ul ain Ali1, Benedek Horváth2,3, Dimitris Kolovos1, Konstantinos Barmpis1,
Ákos Horváth2
1 University of York, York, UK
2 IncQuery Labs cPlc., Budapest, Hungary
3 Johannes Kepler University Linz, Linz, Austria
Contact: Benedek.Horvath@incquerylabs.com
2. Validation of Low-Code System Models
• Low-code platforms adopt Model-Driven Engineering concepts
• Large software system models
• Model correctness is essential
• Scalable cloud resources → $$$
2
SOTA model validation engines should adapt to these needs
3. Cyber-Physical Systems Simulation
• Integrated CPS simulation for industry 4.0
• Queries on continuously changing runtime models
3
SOTA model query engines should adapt to these needs
[1] Márton Búr, Gábor Szilágyi, András Vörös, Dániel Varró: Distributed graph queries over models@run.time
for runtime monitoring of cyber-physical systems. Int. J. Softw. Tools Technol. Transf. 22(1): 79-102 (2020)
Figure source: [1]
4. Epsilon
4
• Epsilon – a family of languages for MDE:
• EOL: model queries
• EVL: model validation
• Model connectivity (EMC): to access the models
Epsilon live: https://www.eclipse.org/epsilon/live/
5. Viatra
5
•Declarative graph query
language
•Transitive closure, negation
cond., etc.
•Compositional, reusable
•Local + Global queries
Definition
•Incremental evaluation
•Cache result set
(RETE networks)
•Maintain incrementally
upon model change
•Local search-based
evaluation
Execution
•On-the-fly validation,
•Works out-of-the-box with
EMF applications,
•View generation,
•Derived features.
Tooling
•AUTOSAR case study
•3 tools compared (Java,
MDT-OCL, IncQuery)
•Scalability measurements
•Load + query
•Manipulate + re-check
•Up to 1.5 million elements
Experiments
https://www.eclipse.org/viatra/
6. Validation Rule Execution in Sequential EVL
• For each Variable Declaration
• Check if there is a Single Variable Access
• Whose variable reference refers to it
• O (|Variable Declaration| x |Single Variable Access| )
• Can be expensive if:
• Single Variable Access is not cached
• Model changes and rules should be reevaluated
6
Viatra with incremental
query engine
7. Overview of the Approach
EVL
validation
program
Translate
constraints to
VQL patterns
Evaluate the
constraints by
calling Viatra
Show results in
Epsilon
Phase I Phase II Phase III
7
11. Benchmarks
• MoDisco EMF model of the Eclipse source code [4]
• FindBugs validation rules in EVL
• Compared performance of:
• Incremental Viatra engine (RETE)
• Local search based Viatra engine (LS)
• Sequential EVL engine
• Measured execution time, memory use of the engines
11
12. Evaluation
• Shortest execution time: RETE
• Longest execution time: Sequential EVL
• Local search engine with base index ~ RETE
• Highest memory use: RETE
• Lowest memory use: Sequential EVL
• Local search engine with base index ~ RETE
12
94 92 88
49
141 133 126
80
284
268
243
183
0
50
100
150
200
250
300
RETE LS with base
index
LS without base
index
Sequential EVL
Memory
use
(MB)
Engine name
Memory use of the engines
100k 200k 500k
0.94 1.35
205.72 205.99
1.77 2.49
883.91 955.62
4.32 6.06
93.19
6390.36
0.10
1.00
10.00
100.00
1000.00
10000.00
RETE LS with base
index
LS without
base index
Sequential EVL
Execution
time
(s)
Engine name
Execution time of the engines
100k 200k 500k
13. Lessons Learnt
• Performance of sequential EVL engine can be improved by Viatra
• Incremental engine speeded-up the execution by 1481x
• Duration of the query translation is negligible
• https://github.com/lowcomote/evl-viatra-prototype
Limitations:
• First-order operations on all instances of model elements
• Single-value references, attributes
• Integrated to EOL, EVL
13
14. Future Work
• Integrate to Epsilon Transformation and Pattern Languages
• Extend supported elements:
• Multi-value references
• User-defined operations
• Performance comparisons with the parallel EVL engine [5]
14
15. Acknowledgements
• This work is partially funded by the European Union’s Horizon
2020 research and innovation programme under the Marie
Skłodowska-Curie grant agreement No 813884,
• and the National Research, Development and Innovation Fund of
Hungary, financed under the 2019-2.1.1-EUREKA-2019-00001
funding scheme.
• The authors are grateful for the valuable feedback of Géza
Kulcsár and the anonymous reviewers about the paper.
15
16. References
[1] Márton Búr, Gábor Szilágyi, András Vörös, Dániel Varró: Distributed graph
queries over models@run.time for runtime monitoring of cyber-physical
systems. Int. J. Softw. Tools Technol. Transf. 22(1): 79-102 (2020)
[2] Dániel Varró, Gábor Bergmann, Ábel Hegedüs, Ákos Horváth, István Ráth,
Zoltán Ujhelyi: Road to a reactive and incremental model transformation
platform: three generations of the VIATRA framework. Softw. Syst. Model.
15(3): 609-629 (2016)
[3] Charles Forgy: Rete: A Fast Algorithm for the Many Patterns/Many
Objects Match Problem. Artif. Intell. 19(1): 17-37 (1982)
[4] http://atenea.lcc.uma.es/projects/LinTra.html
[5] Sina Madani, Dimitrios S. Kolovos, Richard F. Paige: Parallel Model
Validation with Epsilon. ECMFA 2018: 115-131 16