PhD Thesis - Users.encs.concordia.ca

Transcription

University of IsfahanFaculty of Computer EngineeringDepartment of Software EngineeringPhD ThesisTechniques to Compact Model Execution Traces in ModelDriven ApproachSupervisor:Dr. Bahman ZamaniAdvisor:Prof. Abdelwahab Hamou-LhadjBy:Fazilat HojajiJuly 2019

Techniques to Compact Model Execution Traces in Model Driven ApproachA ThesisbyFazilat HojajiSubmitted to the Office of Graduate and Studies ofUniversity of Isfahanin partial fulfillment of the requirements for the degree ofDOCTOR OF PHILOSOPHY IN SOFTWARE ENGINEERINGCommittee Members,Head of Department,Dr. Kamran ZamanifarDr. Shekofeh Kolahdooz RahimiDr. Behroz Tork LadaniJuly 2019Faculty of Computer EngineeringCopyright 2019 Fazilat Hojaji

ABSTRACTModel-Driven Engineering (MDE) is a development paradigm that aims at coping with thecomplexity of systems by separating concerns using models. A model is a representation of aparticular aspect of a system, and defined using a Domain-Specific Modeling Language (DSML). Asubclass of DSMLs aim at supporting the execution of models, namely executable Domain-SpecificModeling Languages (xDSMLs). An xDSML includes execution semantics that manipulate theconcepts of the considered domain. To ensure that an executable model is correct with regard to itsintended behavior, dynamic Verification and Validation (V&V) techniques are used to verify thebehavior of software systems early in the design process. Yet, existing V&V techniques mainly relyon execution traces to model and analyze the behavior of executable models. An execution trace isa sequence containing all the relevant information about an execution over time. Traces, however,tend to be overwhelmingly large, making it difficult to analyze the recorded behavior. There existtrace metamodels to represent execution traces, but most of them suffer from scalability problems.Furthermore, existing model execution tracing approaches rely on their own custom trace formats,hindering interoperability and sharing of data among various trace analysis tools. The goal of thisthesis is to fill this gap and provide a common trace exchange format for traces, designing scalabletrace representations that enables the construction and manipulation of execution traces, obtainedfrom executable models.The first contribution of this thesis comprises a systematic mapping study on existing approaches for tracing executable models. With this study we aim at identifying and classifyingthe existing approaches, thereby assessing the state of the art in this area, as well as pointing topromising directions for further research in this area.The second contribution consists in a generic compact trace representation format called Compact Trace Metamodel (CTM) that enables the construction and manipulation of execution traces,obtained from executable models. Compared to existing trace metamodels, the results show signif1

icant reduction around %59 in memory and %95 disk consumption. Also, the performance overhead required to the CTM trace construction is small enough around %10 that makes it practicallyapplicable. Moreover, CTM offers a common structure, which allows interoperability betweenexisting trace analysis tools.ii

DedicationTo my parents for their love, endless support and encouragement.iii

AcknowledgementThis work would not have been possible without the support and encouragement of the others.I am extremely indebted to my supervisor, Dr. Bahman Zamani, for his teaching, supervision,and patience during doing this thesis. I could not have imagined having a better mentor for myPh.D study.I would like to express my sincere gratitude to my advisor Prof. Abdelwahab Hamou-Lhadj,the associate professor in the Department of Electrical and Computer Engineering at ConcordiaUniversity of Montreal, for the continuous support of my PhD study and research.Besides, I wish to thank Dr. Tanja Mayerhofer and Dr.Erwan Bousse, the members of Business Informatics Group at the Vienna University of Technology, for their continued support, encouragement, and insightful comments during my sabbatical leave and after that.I would like to thank my family: my parents for giving birth to me at the first place, andsupporting me spiritually throughout my life.I would like thank my lab mates in our MDSE Research Group for their continued collaboration and support.Last but not least, deepest thanks go to all people who took part in making this thesis real.iv

TABLE OF CONTENTSPageABSTRACT . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1Dedication . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . iiiAcknowledgement . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ivTABLE OF CONTENTS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .vLIST OF FIGURES . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . ixLIST OF TABLES. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . xi1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .1.11.21.31.41.51Context . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Problem . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Aim of the Research . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Research Methodology . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Structure of the thesis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .12345Foundations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .72. State of the Art . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .8I2.12.22.32.42.5Model-Driven Development . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.1.1 Metamodel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.1.2 Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.1.3 Model Transformation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Model Execution . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.2.1 Execution semantics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.2.2 xDSML . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.2.3 Execution Metamodel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Model Execution Tracing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .A Look at Execution Trace Structures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.4.1 Structures with Specific Concerns . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.4.2 Generic Data Structures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.4.3 Self-defining Trace Formats . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.4.4 Domain-Specific Trace Metamodel Definition Approaches . . . . . . . . . . . . . . . . . . . .Data Serialization Formats. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .v8910111212131416181819192021

3. Abstraction and Compaction Techniques . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 233.13.23.3IITrace Abstraction in Code-Centric Approaches . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3.1.1 Trace Visualization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3.1.2 Trace Exploration. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3.1.3 Abstracting the History of Object Interactions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3.1.4 Graph Reduction. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3.1.5 Partitioning and Clustering. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3.1.6 Program slicing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3.1.7 Pattern Detection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3.1.8 Hiding Components . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Trace Abstraction in Model-Driven Approaches . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3.2.1 Sharing Immutable Objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3.2.2 Avoiding Redundancy in Traces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3.2.3 Recording Modifications of the Dynamic Model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Data Compression Techniques in Database Domain . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3.3.1 Column-Oriented Database Systems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .3.3.2 Rainstor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .23232424252627282929293031313132Contributions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 354. A Taxonomy for Model Execution Tracing Approaches . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 364.14.24.34.44.54.64.7Introduction. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Research Method . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4.2.1 Review Planning . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4.2.2 Review Conduction. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4.2.2.1 Article Selection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4.2.2.2 Data Extraction and Classification Scheme . . . . . . . . . . . . . . . . . . . . . . . . . .Results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4.3.1 Types of Models (Q1) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4.3.2 Semantics Definition Technique (Q2) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4.3.3 Trace Data (Q3) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4.3.4 Purpose (Q4) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4.3.5 Data Extraction Techniques (Q5) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4.3.6 Trace Representation Format (Q6) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4.3.7 Trace Representation Method (Q7) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4.3.8 Language Specificity of Trace Structure (Q8) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4.3.9 Data Carrier Format (Q9) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .4.3.10 Maturity Level (Q10) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Future Research Directions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Limitations and Threats to Validity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Related Work . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .Conclusion. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .vi363738404146545656575859606161626263656670

5. Generic Compact Trace Metamodel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 755.15.25.35.45.5IIIMotivation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 755.1.1 Requirements for an execution trace metamodel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 755.1.2 Limitation of existing trace structures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 76Overview of the Approach . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 78Generic Compact Trace Metamodel. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 805.3.1 Generic trace metamodel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 805.3.2 CTM Compaction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 83Related Work . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 985.4.1 Model execution tracing approaches . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 985.4.2 Business process mining approaches . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1025.4.3 Model persistence approaches . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 103Conclusion. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 105Applications and Tooling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1066. Tool Support in the Context of Gemoc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1076.16.26.36.4IVGemoc Studio Execution Framework . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 107Implementation of CTM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1106.2.1 Generation of proposed trace metamodels in EMF . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1106.2.2 Creation of an xDSML . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1126.2.3 Implementation of the Trace Constructor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1136.2.4 Implementation of the Trace Decompactor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 113Applying Compaction Techniques to CTM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1146.3.1 Implementation of Step Compaction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1146.3.2 Implementation of State Compaction. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1186.3.3 Implementation of Objectstate Compaction. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1206.3.4 Implementation of Parametervalue Compaction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 121Evaluation of CTM. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1216.4.1 Overview on fUML . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1226.4.2 Experiments on CTM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1226.4.3 Results of the Evaluation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 126Conclusion and Perspectives . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1347. Conclusion and Perspectives . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1357.17.2Conclusion. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 135Perspectives . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1377.2.1 Extended pattern detection . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1377.2.2 Further evaluation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1377.2.3 Combining compaction with compression techniques. . . . . . . . . . . . . . . . . . . . . . . . . . 137vii

7.2.47.2.57.2.6Applying lens-like abstraction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 138Applying process mining abstraction techniques. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 138A Tool Suite . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 138Bibliography . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 140Appendix A. CTM Application and Setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 160A.1 Introduction. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 160A.2 Install Eclipse Gemoc Studio . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 160A.2.1 Features in Gemoc Studio 2.3.0 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 162A.3 Download and setup CTM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 164A.3.1 CTM Tool Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 164A.3.2 Launch Configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 165A.3.3 Trace Generation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 165viii

LIST OF FIGURESFIGUREPage1.1Graph of the outline of the thesis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .2.1Petri net abstract syntax . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 102.2Example of Petri net model represented with concrete syntax . . . . . . . . . . . . . . . . . . . . . . . . . . 112.3Example of Petri net model represented as an object diagram . . . . . . . . . . . . . . . . . . . . . . . . . . 113.1Forest of binary trees compression . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 344.1Primary studies selection process . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 424.2Studies retrieved through online libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 434.3Primary studies per year . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 444.4Primary studies per publication type . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 444.5Results of quality assessment of selected primary studies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 464.6Total score for quality assessment questions. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 464.7Classification of model execution tracing approaches. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 555.15.2Approach overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 78CTM generic trace metamodel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 815.3Excerpt of execution trace of the Petri net example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 825.4Excerpt of CTM modeling concepts related to State. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 855.5Excerpt of execution trace (State with compaction) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 865.6Excerpt of CTM with modeling concepts related to Step . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 895.7Excerpt of an execution trace (Step with compaction) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 915.8Excerpt of execution trace (ObjectState without compaction) . . . . . . . . . . . . . . . . . . . . . . . . . 925.9Excerpt of CTM with modeling concepts related to ObjectState . . . . . . . . . . . . . . . . . . . . . . 94ix5

5.10 Excerpt of an execution trace (Objectstate with compaction). . . . . . . . . . . . . . . . . . . . . . . . . . 955.11 Excerpt of CTM with modeling concepts related to ParameterList . . . . . . . . . . . . . . . . . . . 976.1overview of the Gemoc studio . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1086.2Screenshot of GEMOC language workbench . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1096.3Overview of the Gemoc modeling workbench execution framework . . . . . . . . . . . . . . . . . . 1096.4A sample tree (left) and its DAG (right) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1156.5Number of objects used by both CTM traces and domain-specific traces . . . . . . . . . . . . . . 1276.6Number of references used by both CTM traces and domain-specific traces . . . . . . . . . . 1286.7Disk space used by both CTM traces and domain-specific traces . . . . . . . . . . . . . . . . . . . . . . 1286.8Compaction rate of CTM trace elements. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1296.9Runtime overhead of the CTM and domain-specific trace construction, for eachexecuted model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1306.10 Time measurements for CTM trace compaction techniques . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1326.11 Memory consumption measurements for CTM trace elements . . . . . . . . . . . . . . . . . . . . . . . . . 132A.1 Gemoc Studio Installation details . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 161A.2 Screenshot of Gemoc Studio Modeling Workbench on the TFSM example . . . . . . . . . . . 163A.3 Screenshot of the CTM workspace . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 166A.4 An example of debug configuration for a TFSM model. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 167A.5 An excerpt of the trace of an fUML model serialized in XML . . . . . . . . . . . . . . . . . . . . . . . . . 169A.6 An excerpt of the trace of an fUML model serialized in EXI . . . . . . . . . . . . . . . . . . . . . . . . . . . 169x

LIST OF TABLESTABLEPage2.1A selection of execution trace data structures . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213.1Excerpt of order data of a retail system . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 334.1Quality assessment questionnaire . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 454.2Classification of model execution tracing approaches for Q1-Q3 . . . . . . . . . . . . . . . . . . . . . . 724.3Classification of model execution tracing approaches for Q4-Q5 . . . . . . . . . . . . . . . . . . . . . . 734.4Classification of model execution tracing approaches for Q6-Q10 . . . . . . . . . . . . . . . . . . . . . 745.1Excerpt of ObjectState data for the Place objects . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 936.1Result of applying Valiente’s algorithm . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1156.2xDSMLs applied to test our prototype . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1216.3Time measurement, corresponding to each compaction technique . . . . . . . . . . . . . . . . . . . . . 1326.4Memory consumption measurement associated to compaction techniques (all measurements are in KBs). . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 133xi

Chapter 1Introduction1.1ContextIn software engineering, abstraction is a key enabler to deal with the complexity of softwaresystems. Model Driven Development (MDD) is a software development paradigm that aims todecrease the complexity of software systems by raising the level of abstraction in the developmentprocess through the use of models and well-defined modeling languages [1]. In this paradigm,models are the key artifacts in the software development process, and are used to specify thestructure and behavior of the system to be built. One of the main purposes of models is to analyzequality properties of complex systems, for instance to explore design alternatives or to identifypote

PhD Thesis Techniques to Compact Model Execution Traces in Model Driven Approach Supervisor: Dr. Bahman Zamani . Execution Traces in Model Driven Approach A Thesis by Fazilat Hojaji Submitted to the Office of Graduate and Studies of University of Isfahan in partial fulfillment of the requirements for the degree of DOCTOR OF PHILOSOPHY IN .