• Nem Talált Eredményt

2 Backgrounds

2.2 Model Processing

In general, three kinds of model processors are used: traversing processors, template-based processors, and graph transformations [Fowler, 2010]. Traversing processors use the model, visit the model elements and generate code from them (e.g. [Vajk et al, 2009]).

Template-M obile Platform Specific Libraries

M odel transformation M odels describing the aspects

of mobile applications

M obile applications running on different platforms Transformation Engine

supporting multiplatform code generation

@

Web Clients

Business Logic Layer Data Layer

Cloud

based techniques extend this behavior by adding a template document as the base of code generation. Graph transformations [Ehrig et al, 1999] follow a whole different approach; they are basically highly configurable, smart search and replace operations. We specify a domain-specific pattern to search for and a replacement pattern for it. This technique is used in various tools e.g. in GReAT [GReAT] and VMTS [VMTS]. Graph transformations operate like production rules. Graph transformations are easy to use even for non-programmers due to the graphical representation and due to the fact that patterns are built from domain concepts.

In order to use the graph transformation in industrial environments, more scalable graph transformation techniques are required. Recent research directions include for example incremental overlapping rule application [Mészáros et al, 2010], defining declarative graph queries over EMF models, and executing them efficiently [Ujhelyi et al, 2015] and utilization of multi-core architectures [Imre et al, 2012].

Transformations appear in many different situations in a model-based development process. A few representative examples are as follows. (i) Refining the design to implementation; this is a basic case of platform-independent model to platform-specific model mapping [Kelly et al, 2008]. (ii) Aspect weaving; the integration of aspect models/code into functional artifacts is a transformation on the design [Gray et al, 2004]. (iii) Generative techniques; the implementation of generative paradigms is often realized with model transformation [Czarnecki et al., 2000]. (iv) Analysis and verification; analysis algorithms can be expressed as transformations on the design [Assmann, 1996].

We can conclude that transformations in general play an essential role in model-based development, thus, there is a need for model transformation solutions [Levendovszky et al, 2009a].

2.2.1 Model-Driven Architecture

Model-Driven Architecture (MDA) [OMG MDA] offers a standardized framework to separate the essential, platform-independent information from the platform-dependent constructs and assumptions. A complete MDA application consists of a definitive platform-independent model (PIM), one or more platform-specific models (PSM) including complete implementations, one on each platform that the application developer decides to support. The platform-independent artifacts are UML and different software models containing enough specification to generate the platform-dependent artifacts automatically by model compilers (Figure 2-2).

MDA development focuses first on the functionality and behavior of a distributed application or system, undistorted by characteristics of the technology platform or platforms on which it will be implemented. In this way, MDA separates implementation details from business functions. Thus, it is not necessary to repeat the process of defining a functionality of the application or a system behavior each time a new technology arises. With MDA, functionality and behavior are modeled once. Then, mapping from a PIM through a PSM to the supported MDA platforms is implemented by different model transformations, which ease the challenge of supporting new or different technologies and areas.

Figure 2-2 Overview of the Model-Driven Architecture 2.2.2 Model Integrated Computing

Model Integrated Computing (MIC) [Sztipanovits et al. 1997] is a model-based approach to software development. MIC facilitates the synthesis of application programs from models created using customized, domain-specific program synthesis environments. MIC focuses on models, supports the flexible creation of modeling environments, and helps following the changes of the models. At the same time it facilitates code generation and provides tool support for converting the created models into code artifacts. MIC was the first methodology, which requires metamodeling environments, model processors and provides a framework for them to cooperate and create computer-based systems in the practice [Sztipanovits, 1998].

The MIC development cycle (Figure 2-3) starts with the formal specification of a new application domain. The specification proceeds by identifying the domain concepts, together with their attributes and inter-relationships using metamodeling. After the domain has been defined, the metamodel of the domain is used to generate a domain-specific design environment. The specific design environment can then be used to create domain-specific models. The next step to synthesize executable code, perform analysis or drive simulators. This is achieved by converting the models into another format such as executable code, input language of analysis tools, or configuration files for simulators. This mapping of the models to another useful form is achieved by model transformation. Model transformations are programs that convert models in a given domain into models of another domain. Note that the result of the transformation can be considered a model that conforms to a different metamodel.

MIC can be used as a methodology for domain-specific MDA where the focus is on developing the MDA process for specific domains. An implementation of domain-specific MDA should consist of a domain-specific modeling environment that allows users to describe

systems, using domain concepts. This environment is then used to develop domain-specific platform-independent models. These models represent the behavior and structure of the system with no implementation details. Such models then need to be converted to specific platform-specific models. These models could either be based on the use of domain-specific libraries and frameworks or they do not have any domain-domain-specific information.

Figure 2-3 Overview of the Model Integrated Computing 2.2.3 Model Transformation in the Cloud

In order to use graph transformation in industrial environments, scalable graph transformation techniques are required. This leads to approaches to store [Vajk et al, 2012] and execute transformations in the cloud [Clasen et al, 2012]. Weaving of MDE and cloud technologies seems natural and may result in unprecedented performance boost in model-based tools [Alajrami et al, 2014]. This approach can be referred to as Modeling as a Service (MaaS) according to [Bruneliere et al, 2010]. The main advantage of in-cloud transformations is the possibility to parallelize their execution.