Constructing a bidirectional transformation between BPMN and BPEL with a functional logic programming language - Mazanek, Steffen; Hanus, Michael (Journal of visual languages and computing, 2011)
In this article we show how functional logic programming techniques can be used to construct a bidirectional transformation between structured process models of the business process modeling notation (BPMN) and executable models of the business process execution language (BPEL). We specify the abstract syntax of structured process models by a context-free hypergraph grammar. This grammar can be subsequently transformed into a graph parser using our previously developed G rappa framework of functional logic GRAPh PArser combinators. The G rappa framework has been implemented using the functional logic programming language Curry. Furthermore, we show how the constructed parsers can be enriched with semantic computations as required for the synthesis of BPEL from BPMN. Since our parser is a function implemented in a functional logic language, it can be applied in both directions. Thus, given a BPEL model, a corresponding BPMN graph can be constructed with the very same parser. Finally, logic-based parsers can be used for model completion and language generation in a straightforward way. In order to be self-contained, this article also surveys context-free hypergraph grammars, the concepts of the programming language Curry, the example languages BPMN and BPEL, and the ideas of the G rappa framework. Actually, this article is a literate Curry program and, as such, directly executable. Thus, it contains the complete concise source code of our application. ► Functional logic languages are well-suited for certain model transformation tasks. ► Graphs, and thus also models, can be analyzed using parser combinators. ► A bidirectional transformation between BPMN and BPEL in 30 readable LOCs. ► Our parsers can be applied in both directions and, thus, are also generators.