Incremental Evaluation of Model Queries over EMF Models
Model-driven development tools built on industry standard platforms, such as the EclipseModeling Framework (EMF), heavily utilize model queries in model transformation, well-formedness constraint validation and domain-specific model execution. As these queries are executed rather frequently in interactive modeling applications, they have a significant impact on runtime performance and end user experience. However, due to their complexity, these queries can be time consuming to implement and optimize on a case-by-case basis. Consequently, there is a need for a model query framework that combines an easy-to-use and concise declarative query formalism with high runtime performance.
In this paper, we propose a declarative EMF model query framework using the graph pattern formalism as the query specification language. These graph patterns describe the arrangement and properties of model elements that correspond to, e.g. a well-formedness constraint, or an application context of a model transformation rule.
For improved runtime performance, we employ incremental pattern matching techniques: matches of patterns are stored and incrementally maintained upon model manipulation. As a result, query operations can be executed instantly, independently of the complexity of the constraint and the size of the model. We demonstrate our approach in an industrial (AUTOSAR) model validation context and compare it against other solutions.
KeywordsEMF model query incremental pattern matching model validation
Unable to display preview. Download preview PDF.
- 1.The Eclipse Project: Eclipse Modeling Framework, http://www.eclipse.org/emf
- 2.The Eclipse Project: MDT OCL, http://www.eclipse.org/modeling/mdt/?project=ocl
- 3.The Eclipse Project: EMF Model Query, http://www.eclipse.org/modeling/emf/?project=query
- 4.Bergmann, G., Ökrös, A., Ráth, I., Varró, D., Varró, G.: Incremental pattern matching in the VIATRA model transformation system. In: Karsai, G., Taentzer, G. (eds.) Graph and Model Transformation (GraMoT 2008). ACM, New York (2008)Google Scholar
- 5.AUTOSAR Consortium: The AUTOSAR Standard, http://www.autosar.org/
- 7.Rensink, A.: Representing first-order logic using graphs. In: Ehrig, H., Engels, G., Parisi-Presicce, F., Rozenberg, G. (eds.) ICGT 2004. LNCS, vol. 3256, pp. 319–335. Springer, Heidelberg (2004)Google Scholar
- 10.The Eclipse Project: EMFT Search, http://www.eclipse.org/modeling/emft/?project=search
- 12.Giese, H., Hildebrandt, S., Seibel, A.: Improved flexibility and scalability by interpreting story diagrams. In: Magaria, T., Padberg, J., Taentzer, G. (eds.) Proceedings of GT-VMT 2009. Electronic Communications of the EASST, vol. 18 (2009)Google Scholar
- 13.The Object Management Group: Object Constraint Language, v2.0 (May 2006), http://www.omg.org/spec/OCL/2.0/
- 18.Mészáros, T., et al.: Manual and automated performance optimization of model transformation systems. Software Tools for Technology Transfer (2010) (to appear)Google Scholar
- 19.Giese, H., Wagner, R.: From model transformation to incremental bidirectional model synchronization. Software and Systems Modeling (SoSyM) 8(1) (March 2009)Google Scholar