Model Driven Architecture MDA
Post date: Aug 27, 2014 8:35:21 PM
Gartner identified MDA as an "on the rise" technology in its 2006 "Hype Cycle". There were others who promoted, praised and supported this concept. In year 2014 while managers, clients and organizations are focusing on Agile development (everything agile) focus on MDA seems lost but there are strong reasons to believe on engineering side of the software development (more argument on this topic later).
Note: There were many companies or organizations who were working in this area and they had some tools for MDA but many of them moved their products to opensource, went to eclipse project. Some of them were acquired. If you try to look into this topic you will find most of the writings from year 2002 to 2004 or maximum till 2006. So it is a dead topic (looks like).
What is MDA or model driven architecture?
Basic idea is to model the domain or business (requirements) and the model should not be platform, programming language or computation specific. It should represent the business.
The advantage of this approach is that you have a model using which you should be able to go for any language or platform of your choice for implementation. If you don't follow this approach and you only have a platform specific model/code it will be difficult to change the platform. If you have a platform independent model, using a transformation tool you can create platform specific model of your preferred language or platform and by using another tool you can generate code from this platform specific model.
Platform independent model is the starting of MDA. Generally it is created using UML (unified modeling language) but as per OMG (object management group who defines the specification) UML is not mandatory to define PIM or other MDA models. OMG specification says: "model can be created using any modeling language which is based on MOF (MetaObject Facility). PIM models business functionality in platform and language neutral way.
PIM can further be divided in to two parts: computation independent model (CIM) and platform independent component model (PICM)
Platform specific model is the model which is derived from PIM and this translation is done by MDA tools.
From PSM, code can be generated using tools.
It defines how PIM will be transformed in to PSM. It is rules to transform PIM to PSM.
Process of converting PIM to PSM
Unified Modeling Language (UML) [Note: not mandatory as per OMG]
Meta-Object Facility (MOF)
XML Metadata Interchange (XMI)
Enterprise Distributed Object Computing (EDOC)
Software Process Engineering Metamodel (SPEM)
Common Warehouse Metamodel (CWM)
Steps in MDA
Open source tools
Factors to consider while selecting a MDA tool
Full MDA tool or partial (PIM to code generation and vice versa complete round-trip)
Code generation method
Script language (if applicable)
PIM to PSM capability
Version of Meta Object Facility (MOF)
XMI import/export support
Commercial or Opensource (License cost to use for commercial purposes)
Support for executable model creation and ease of creating executable models
Vendor lock-in due to generated code
Executable models is the core of this concept. For this purpose code and executable models are considered to be the same. So if you have a model which can be executed then you have faster cycles of model to build, running the test and doing it again. Now to make it agile first thing you have to do it leave analysis and design models aside. There is only one thing and it is executable model and that is equivalent to code.
A UML profile defines execution rules. Set of classes and objects communicate using state machine. On change of state, state machine triggers actions and this way functional computation, data access etc is executed.
The idea is good but there are and were some practical difficulties:
1. Transformation tools without vendor locking had been a challenge due to interoperability (also see point number 4 bellow)
2. Do we really go to implement our application from one programming language to another? If not often, what is the use of platform independent model? This raises question of value proposition. Another angle to this is quality of code produced: We know that complexity of the problem (business requirements) is going to exist whether you use MDA or not. Maintaining quality of generated code can be a concern when it is produced by translation or transformation from an abstract level model.
3. Specifications (MDA) were not complete for a long time so how things could work seamlessly?
4. Are implementers of tools (major vendors) ready to adhere to common standards so that tools and transformation can correctly work on the PIM? They never agree because if all of them start producing things without their own propriety specific feature why one would buy their costly licenses.
5. In the age of (and in the name of) agile/scrum and daily builds, do people really care about creating models and those models in such a way that code/skeleton can be generated? I have heard many project teams saying our code is our mode and design.
6. Tool vendors presented very good products but complete round-trip ( Abstract mode to specific mode land then code or vice versa) was not 100% successful in all the scenarios.
Research papers on tools comparison:
1. Comparative analysis if MDA tools: http://www.studiainformatica.ii.uph.edu.pl/download/124.pdf
2. An evaluation of Model Driven Architecture tools: http://csb.uncw.edu/mscsis/complete/pdf/RichardAlford.pdf
3. Comparison of MDA tools: http://www.wittmannclan.com/ptr/cs/mda_compare.pdf
1. Comparison of Model-Driven Architecture and Software Factories in the Context of Model-Driven Development ftp://ftp.inf.puc-rio.br/pub/docs/FomularioSolicitacoes/LeandraMara-06-08-23494.pdf
2. MDA specification: http://www.omg.org/mda/specs.htm
5. Model Driven Development for J2EE Utilizing a Model Driven Architecture (MDA) approach http://www.omg.org/mda/mda_files/MDA_Comparison-TMC_final.pdf
6. Modeling approaches: http://www.agilemodeling.com/essays/modelingApproaches.htm