Practical aspects of bidirectional graph transformations

  • Authors:
  • Zhenjiang Hu

  • Affiliations:
  • National Institute of Informatics, Tokyo, Japan

  • Venue:
  • PEPM '13 Proceedings of the ACM SIGPLAN 2013 workshop on Partial evaluation and program manipulation
  • Year:
  • 2013

Quantified Score

Hi-index 0.00

Visualization

Abstract

Bidirectional transformation consists of a pair of transformations, describing not only a forward transformation from a source to a view, but also a backward transformation showing how to reflect the changes in the view to the source. Bidirectional transformation provides a novel mechanism for synchronizing and maintaining the consistency of information between input and output, and has many potential applications in software development, including model synchronization, round-trip engineering, software evolution, multiple-view software development, reverse software engineering, as well as the well-known view updating mechanism which has been intensively studied in the database community for decades. To support systematical development of well-behaved bidirectional transformations, much research has been devoted to design of bidirectional languages that can be interpreted both forwardly and backwardly while guaranteeing the roundtrip property between the forward and the backward transformations. Despite many promising results, most of them are limited to lists and trees. In fact, there are challenges in designing a language for bidirectional transformation on graphs. First, unlike lists and trees, there is no unique way to represent, construct, and decompose a general graph, which requires more precise definition of equivalence between two graphs. Second, graphs have sharing nodes and cycles, which makes forward computation much more complicated than that on trees (let alone to say about backward computation), where naive computation on graphs would visit the same nodes many times and possibly infinitely often. We have challenged the problem of bidirectional transformations on graphs, and succeeded in bidirectionalizing graph queries (in UnQL) and implementing a bidirectional graph transformation engine called GRoundTram. In GRoundTram, graphs are treated as regular trees and manipulated by structural recursion that enjoys a nice bulk and bidirectional semantics. Although GRoundTram has been successfully applied to nontrivial model-code co-evolution, there are still many practical issues that should be addressed to make it be more useful. In this talk, I shall briefly explain our solution to the problem of bidirectional graph transformation and demonstrate some applications in bidirectional model-driven software development, and focus on discussing practical issues in manipulating various graphs (such as unordered, ordered, and probability graphs), determining backward transformation, and improving efficiency and scalability.