In rule-based approaches, a model transformation definition tells how an instance of a source metamodel should be transformed to an instance of a target metamodel. As these metamodels undergo changes, model transformations defined over these metamodels may get out of sync. Restoring conformance between model transformations and the metamodels is a complex and error-prone task. In this paper, we propose a formal approach to automatically co-evolve model transformations according to the evolution of the metamodels. The approach is based on encoding the model transformation definition as a query-retyping combination and the evolution of the metamodels as applications of graph transformation rules. These rules are used to obtain an evolved query over the evolved metamodel together with a new retyping from the target metamodel. We will identify the criteria which need to be fulfilled in order to make this automatic co-evolution possible. We provide a tool support for this procedure, in which, from a traceability model that represents the original model transformation definition, we derive a co-evolved traceability model that represents the evolved transformation definition. Moreover, we use a case study to evaluate the approach with a set of commonly performed metamodel evolutions.
Read full abstract