Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Keynote Extreme Modelling 2014

489 views

Published on

Slides from my keynote at XM 2014. http://www.di.univaq.it/XM2014/

Published in: Software
  • Be the first to comment

  • Be the first to like this

Keynote Extreme Modelling 2014

  1. 1. Putting Engineering into MDE Components and contracts for models and transformations Steffen Zschaler 29 September, 2014 With (lots of) help by Francisco Duran, Jeffrey Terrell, Jendrik Johannes, Dimitris Kolovos, and many others All errors my own!
  2. 2. Motivation • MDE is beginning to see some use – Automotive – Telecommunications – Enterprise systems (especially for quality prediction) • Need for systematic engineering – To deal with scale of models – To deal with complexity of domains – To ensure correctness so MDE techniques can be relied on 29/09/2014 (c) Steffen Zschaler 2
  3. 3. Motivation (2) • Elements of systematic MDE engineering – Requirements – Architectures – (Reusable) Components – Patterns and Architecture Styles – Methods and Guidelines A research agenda for the years to come 29/09/2014 (c) Steffen Zschaler 3
  4. 4. Motivation (2) • Elements of systematic MDE engineering – Requirements – Architectures – (Reusable) Components – Patterns and Architecture Styles – Methods and Guidelines A research agenda for the years to come 29/09/2014 (c) Steffen Zschaler 3
  5. 5. A framework for discussing composition 29/09/2014 (c) Steffen Zschaler 4 Uwe Aßmann: Invasive Software Composition.
  6. 6. A framework for discussing composition Component Model (incl. contracts) 29/09/2014 (c) Steffen Zschaler 4 Uwe Aßmann: Invasive Software Composition.
  7. 7. A framework for discussing composition Composition Model (composition technique) Component Model (incl. contracts) 29/09/2014 (c) Steffen Zschaler 4 Uwe Aßmann: Invasive Software Composition.
  8. 8. A framework for discussing composition Composition Language Composition Model (composition technique) Component Model (incl. contracts) 29/09/2014 (c) Steffen Zschaler 4 Uwe Aßmann: Invasive Software Composition.
  9. 9. A framework for discussing composition Composition System Composition Language Composition Model (composition technique) Component Model (incl. contracts) 29/09/2014 (c) Steffen Zschaler 4 Uwe Aßmann: Invasive Software Composition.
  10. 10. Outline 1. Motivation 2. Models 3. Transformations 4. Challenges 29/09/2014 (c) Steffen Zschaler 5
  11. 11. Outline 1. Motivation 2. Models 3. Transformations 4. Challenges 1. Composition techniques 2. Contracts 29/09/2014 (c) Steffen Zschaler 5
  12. 12. Model components • Variety of approaches – Model/Package Import – AOM • Package Merge • Language-specific merges – E.g., for sequence diagrams – RAM, MATA, ... • Generic merges – E.g., GeKo, Reuseware, ... 29/09/2014 (c) Steffen Zschaler 6
  13. 13. Model components Example 1 29/09/2014
  14. 14. Model components Example 1 29/09/2014
  15. 15. Model components Example 2 29/09/2014 (c) Steffen Zschaler 8
  16. 16. Model components Example 2 29/09/2014 (c) Steffen Zschaler 8
  17. 17. Model components Example 2 29/09/2014 (c) Steffen Zschaler 8
  18. 18. Model components Example 2 29/09/2014 (c) Steffen Zschaler 8
  19. 19. Model components Example 2 29/09/2014 (c) Steffen Zschaler 8
  20. 20. Model components Example 2 29/09/2014 (c) Steffen Zschaler 8
  21. 21. Model components Example 2 29/09/2014 (c) Steffen Zschaler 8
  22. 22. Model components Contracts? • Only syntactical, if any – Meta-classes of elements expected – Naming and signatures of operations • Key exception: Rely-Guarantee Specifications – For temporal logic and state machines 29/09/2014 (c) Steffen Zschaler 9
  23. 23. Syntactic Contracts 29/09/2014 (c) Steffen Zschaler 10
  24. 24. Syntactic Contracts 29/09/2014 (c) Steffen Zschaler 10
  25. 25. Syntactic Contracts 29/09/2014 (c) Steffen Zschaler 10
  26. 26. Outline 1. Motivation 2. Models 3. Transformations 4. Challenges 1. Composition techniques 2. Contracts 29/09/2014 (c) Steffen Zschaler 11
  27. 27. Transformation Composition 29/09/2014 (c) Steffen Zschaler 12
  28. 28. Transformation Composition External Internal 29/09/2014 (c) Steffen Zschaler 12
  29. 29. Transformation Composition External Internal Sequential T1 M1 M2 M3 T2 29/09/2014 (c) Steffen Zschaler 12
  30. 30. Transformation Composition External Internal Sequential Rule Superimposition (aka import with replacement) 29/09/2014 (c) Steffen Zschaler 12
  31. 31. Transformation Composition External Internal Sequential Rule Superimposition (aka import with replacement) M1 M2 29/09/2014 (c) Steffen Zschaler 12
  32. 32. Transformation Composition External Internal Sequential Parallel Rule Superimposition (aka import with replacement) T1 M1 M2 M3 T2 M4 M5 29/09/2014 (c) Steffen Zschaler 12
  33. 33. Transformation Composition External Internal Sequential Parallel Rule Superimposition (aka import with replacement) Rule Weaving (aka full aspect orientation) 29/09/2014 (c) Steffen Zschaler 12
  34. 34. Transformation Composition External Internal Sequential Parallel Rule Superimposition (aka import with replacement) Rule Weaving (aka full aspect orientation) M1 M2 29/09/2014 (c) Steffen Zschaler 12
  35. 35. Transformation Composition Sequential Class Model OO to Relational Table Model 29/09/2014 (c) Steffen Zschaler 13
  36. 36. Transformation Composition Sequential Table Model Normalised Table Model Normalisation 29/09/2014 (c) Steffen Zschaler 13
  37. 37. Transformation Composition Sequential Class Model OO to Relational Table Model Normalised Table Model Normalisation 29/09/2014 (c) Steffen Zschaler 13
  38. 38. Transformation Composition Parallel :Table * <<hook>> :Column Based on Jendrik Johannes, Steffen Zschaler, Miguel A. Fernández, Antonio Castillo, Dimitrios S. Kolovos, Richard F. Paige: Abstracting Complex Languages through Transformation and Composition. MODELS 2009, LNCS 5795, pp 546–550.
  39. 39. Transformation Composition Parallel :Table :Class * <<hook>> :Column Based on Jendrik Johannes, Steffen Zschaler, Miguel A. Fernández, Antonio Castillo, Dimitrios S. Kolovos, Richard F. Paige: Abstracting Complex Languages through Transformation and Composition. MODELS 2009, LNCS 5795, pp 546–550.
  40. 40. Transformation Composition Parallel :Table :Class * <<hook>> :Column :Attribute Based on Jendrik Johannes, Steffen Zschaler, Miguel A. Fernández, Antonio Castillo, Dimitrios S. Kolovos, Richard F. Paige: Abstracting Complex Languages through Transformation and Composition. MODELS 2009, LNCS 5795, pp 546–550.
  41. 41. Transformation Composition Parallel :Table :Class * <<hook>> :Column <<anchor>> :Column :Attribute Based on Jendrik Johannes, Steffen Zschaler, Miguel A. Fernández, Antonio Castillo, Dimitrios S. Kolovos, Richard F. Paige: Abstracting Complex Languages through Transformation and Composition. MODELS 2009, LNCS 5795, pp 546–550.
  42. 42. Transformation Composition Parallel :Table :Class * <<hook>> :Column <<anchor>> :Column :Attribute Based on Jendrik Johannes, Steffen Zschaler, Miguel A. Fernández, Antonio Castillo, Dimitrios S. Kolovos, Richard F. Paige: Abstracting Complex Languages through Transformation and Composition. MODELS 2009, LNCS 5795, pp 546–550.
  43. 43. Transformation Composition Parallel :Table :Class super sub :Class * <<hook>> :Column <<anchor>> :Column :Attribute Based on Jendrik Johannes, Steffen Zschaler, Miguel A. Fernández, Antonio Castillo, Dimitrios S. Kolovos, Richard F. Paige: Abstracting Complex Languages through Transformation and Composition. MODELS 2009, LNCS 5795, pp 546–550.
  44. 44. Transformation Composition Parallel <<anchor>><<slot>> :Table * <<hook>> :Column <<anchor>> :Column :Class super sub :Class :Attribute Based on Jendrik Johannes, Steffen Zschaler, Miguel A. Fernández, Antonio Castillo, Dimitrios S. Kolovos, Richard F. Paige: Abstracting Complex Languages through Transformation and Composition. MODELS 2009, LNCS 5795, pp 546–550.
  45. 45. Transformation Composition Parallel <<anchor>><<slot>> :Table * <<hook>> :Column <<anchor>> :Column <<anchor>><<slot>> :Table * <<hook>> :Column :Class super sub :Class :Attribute Based on Jendrik Johannes, Steffen Zschaler, Miguel A. Fernández, Antonio Castillo, Dimitrios S. Kolovos, Richard F. Paige: Abstracting Complex Languages through Transformation and Composition. MODELS 2009, LNCS 5795, pp 546–550.
  46. 46. Transformation Composition Parallel Weaving <<anchor>><<slot>> :Table * <<hook>> :Column <<anchor>> :Column <<anchor>><<slot>> :Table * <<hook>> :Column :Class super sub :Class :Attribute Weaving Based on Jendrik Johannes, Steffen Zschaler, Miguel A. Fernández, Antonio Castillo, Dimitrios S. Kolovos, Richard F. Paige: Abstracting Complex Languages through Transformation and Composition. MODELS 2009, LNCS 5795, pp 546–550.
  47. 47. Transformation Composition Superimposition module Class2Relational; create OUT : Relational from IN : Class; rule Class2Table { Based on Lawley, M., Duddy, K., Gerber, A., Raymond, K. Language Features for Re-Use and Maintainability of MDA Transformations. OOPSLA & GPCE Workshop, 2004 and: Jouault, F. and Kurtev, I. Transforming models with ATL. In: Satellite Events at the MoDELS 2005 Conference, Oct 2005, Montego Bay, Jamaica. pp. 128-138, LNCS 3844 (long version from http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.99.6117&rep=rep1&type=pdf ) from c : Class!Class to out : Relational!Table ( name <- c.name, col <- Sequence {key} ->union(c.attr)), key : Relational!Column ( name <- 'objectId', type <- objectIdType) } rule Attribute2Column { from a : Class!Attribute to out : Relational!Column ( name <- a.name, type <- a.type) } 29/09/2014 (c) Steffen Zschaler 15
  48. 48. Transformation Composition Superimposition module Class2Relational; create OUT : Relational from IN : Class; rule Class2Table { module Class2RelationalInheritance; create OUT : Relational from IN : Class; rule Class2Table { Based on Lawley, M., Duddy, K., Gerber, A., Raymond, K. Language Features for Re-Use and Maintainability of MDA Transformations. OOPSLA & GPCE Workshop, 2004 and: Jouault, F. and Kurtev, I. Transforming models with ATL. In: Satellite Events at the MoDELS 2005 Conference, Oct 2005, Montego Bay, Jamaica. pp. 128-138, LNCS 3844 (long version from http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.99.6117&rep=rep1&type=pdf ) from c : Class!Class to out : Relational!Table ( name <- c.name, col <- Sequence {key} ->union(c.attr)), key : Relational!Column ( name <- 'objectId', type <- objectIdType) } rule Attribute2Column { from a : Class!Attribute to out : Relational!Column ( name <- a.name, type <- a.type) } from c : Class!Class ( c.parent.oclIsUndefined()) to out : Relational!Table ( name <- c.name, col <- Sequence {key} ->union(c.flattenedFeatures)), key : Relational!Column ( name <- 'objectId', type <- objectIdType) } -- flattenedFeatures helper not shown. -- It collects all features of a class -- and all its sub-classes 29/09/2014 (c) Steffen Zschaler 15
  49. 49. Transformation Composition Superimposition module Class2Relational; create OUT : Relational from IN : Class; rule Class2Table { Based on Lawley, M., Duddy, K., Gerber, A., Raymond, K. Language Features for Re-Use and Maintainability of MDA Transformations. OOPSLA & GPCE Workshop, 2004 and: Jouault, F. and Kurtev, I. Transforming models with ATL. In: Satellite Events at the MoDELS 2005 Conference, Oct 2005, Montego Bay, Jamaica. pp. 128-138, LNCS 3844 (long version from http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.99.6117&rep=rep1&type=pdf ) from c : Class!Class to out : Relational!Table ( name <- c.name, col <- Sequence {key} ->union(c.attr)), key : Relational!Column ( name <- 'objectId', type <- objectIdType) } rule Attribute2Column { from a : Class!Attribute to out : Relational!Column ( name <- a.name, type <- a.type) } ( c.parent.oclIsUndefined()) to out : Relational!Table ( name <- c.name, col <- Sequence {key} ->union(c.flattenedFeatures)), key : Relational!Column ( name 'objectId', type <- objectIdType) } -- flattenedFeatures helper -- not shown... 29/09/2014 (c) Steffen Zschaler 15
  50. 50. Transformation Composition Weaving 29/09/2014 (c) Steffen Zschaler 16
  51. 51. Transformation Composition Weaving 29/09/2014 (c) Steffen Zschaler 16
  52. 52. Contracts • Need both syntactical and semantic contracts • Goal: – Be precise enough to enable reasoning and give assurances – Be lenient enough to maximise reusability 29/09/2014 (c) Steffen Zschaler 17
  53. 53. Contracts (2) Will look at two types of contracts: – Syntactic contracts for sequential composition (aka model typing) – Semantic contracts for rule weaving 29/09/2014 (c) Steffen Zschaler 18
  54. 54. Contracts for sequential composition Class Model OO to Relational Table Model • Contracts specify the kinds of models read and written by a transformation • Options: 1. Meta-models 2. Effective meta-models 3. Model types / Concepts Normalised Table Model Normalisation 29/09/2014 (c) Steffen Zschaler 19
  55. 55. Model typing problems mmo NewSM (s : Simple) { s += new StateMachine () } S. Zschaler: Towards Constraint-Based Model Types: A Generalised Formal Foundation for Model Genericity. In VAO’14
  56. 56. Model typing problems mmo NewSM (s : Simple) { s += new StateMachine () } StateMachine initialState 0..1 State name: String Transition event: String containedState * src 1 tgt 1 incoming * * outgoing S. Zschaler: Towards Constraint-Based Model Types: A Generalised Formal Foundation for Model Genericity. In VAO’14
  57. 57. Model typing problems mmo NewSM (s : Simple) { s += new StateMachine () } StateMachine initialState 0..1 State name: String Transition event: String containedState * src 1 tgt 1 incoming * * outgoing Difference between Mandatory-start <: Simple and Mandatory-start Steel Simple S. Zschaler: Towards Constraint-Based Model Types: A Generalised Formal Foundation for Model Genericity. In VAO’14
  58. 58. Model typing problems Mandatory-start <:Steel Simple mmo NewSM (s : Simple) { s += new StateMachine () } StateMachine initialState 0..1 State name: String Transition event: String containedState * src 1 tgt 1 incoming * * outgoing Difference between Simple and Mandatory-start Error: Allows passing in Mandatory-start instance, but breaks it. S. Zschaler: Towards Constraint-Based Model Types: A Generalised Formal Foundation for Model Genericity. In VAO’14
  59. 59. mmo NewSM (s : Simple) { sm := new StateMachine () ; sm.initialState += new State () ; s += sm } Model typing problems StateMachine initialState 0..1 State name: String Transition event: String containedState * src 1 tgt 1 incoming * * outgoing Difference between Mandatory-start <: Simple and Mandatory-start Guy Simple S. Zschaler: Towards Constraint-Based Model Types: A Generalised Formal Foundation for Model Genericity. In VAO’14
  60. 60. Mandatory-start <:Guy Simple mmo NewSM (s : Simple) { sm := new StateMachine () ; sm.initialState += new State () ; s += sm } Model typing problems StateMachine initialState 0..1 State name: String Transition event: String containedState * src 1 tgt 1 incoming * * outgoing Difference between Simple and Mandatory-start Over-restriction: Would work with Mandatory-start instance, but cannot specify. S. Zschaler: Towards Constraint-Based Model Types: A Generalised Formal Foundation for Model Genericity. In VAO’14
  61. 61. Syntactic contracts: Research challenges • Type theory of transformations – Including intrinsic and extrinsic contracts • Static analysis of transformations – Data flow analysis • Tool support for managing and checking transformation contracts 29/09/2014 (c) Steffen Zschaler 21
  62. 62. Contracts for rule weaving 29/09/2014 (c) Steffen Zschaler 22
  63. 63. Contracts for rule weaving 29/09/2014 (c) Steffen Zschaler 22
  64. 64. Contracts for rule weaving • Morphisms over transformation systems – Both for parameter and bindings • Define Properties of morphisms to ensure semantics of weaving – Behaviour reflection and preservation  Semantic contracts 29/09/2014 (c) Steffen Zschaler 23
  65. 65. Semantic contracts: Research challenges • Other semantic properties – Allow some change of behaviour – Express behaviour of base parametrised over transformations to be woven 29/09/2014 (c) Steffen Zschaler 24
  66. 66. Semantic contracts: Research challenges • Other semantic properties – Allow some change of behaviour – Express behaviour of base parametrised over transformations to be woven M1 M2 τ 29/09/2014 (c) Steffen Zschaler 24
  67. 67. Semantic contracts: Research challenges • Other semantic properties – Allow some change of behaviour – Express behaviour of base parametrised over transformations to be woven M1 M2 τ sem1 sem2 ζ Γ1 Γ2 29/09/2014 (c) Steffen Zschaler 24
  68. 68. Semantic contracts: Research challenges • Other semantic properties – Allow some change of behaviour – Express behaviour of base parametrised over transformations to be woven M1 M2 τ(τ1, .. , τn) f(ζ1, .. , ζn) sem1 sem2 ζ Γ1 Γ2 29/09/2014 (c) Steffen Zschaler 24
  69. 69. Outline 1. Motivation 2. Models 3. Transformations 4. Challenges 29/09/2014 (c) Steffen Zschaler 25
  70. 70. Research Agenda • Need a calculus of transformation components – What do they look like? – What composition operations are there? – What are contracts? – What properties can we derive for composite transformations? • Some work exists: – See talk – Megamodelling (e.g., MINNT for typing) • But are still missing fundamental theory 29/09/2014 (c) Steffen Zschaler 26
  71. 71. http://xkcd.com/1343/ 29/09/2014 (c) Steffen Zschaler

×