Web technologies: Model Driven Engineering
-
Upload
piero-fraternali -
Category
Technology
-
view
906 -
download
1
description
Transcript of Web technologies: Model Driven Engineering
![Page 1: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/1.jpg)
Web Technologies
Introduction to Model Driven Engineering
Piero [email protected]
Skype: pierofraternali
![Page 2: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/2.jpg)
Models: a meeting place for developers & users
![Page 3: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/3.jpg)
Motivations
• “Supply of talented IT staffers isn't keeping up with demand. And it won't change anytime soon.” – Eric Chabrow, in The
New IT Worker Shortage, CIOInsight 2009
#programmers
#applications
2005 2010 2015 2020
![Page 4: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/4.jpg)
From crafting to fabrication
• Engineering addresses the optimization of production by means of abstraction and standardization
• Products are modeled, verified, and produced using standard models and methods
![Page 5: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/5.jpg)
Models
• A model is an ABSTRACT REPRESENTATION of a product, service or system that allows us to investigate, verify, and document its properties BEFORE production
![Page 6: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/6.jpg)
Software as an engineering product
• SW is an engineering product
• BUT:– It can be changed easily,
even after delivery and during usage
– It is produced in short time and at low cost
– It must satisfy a broad spectrum of requisities, hard to quantify
• SO engineering practices are not always applied
![Page 7: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/7.jpg)
Software Models
• Software Engineering has a long tradition on the use of abstraction and software models
• MODEL DRIVEN ENGINEERING• SOFTWARE MODELS are
– An abstract representation of a system, independent of technology
– A tool for expressing and verifying requirements– A starting point for automatically generating the
code
![Page 8: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/8.jpg)
History
• Software models are as old as software
• Flow diagrams were the first tool for describing software
• Programming language and models evolved together– Imperative programming –
flow diagrams– Info systems – ER– OO systems – object models
![Page 9: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/9.jpg)
Milestones
P.- ChenThe Entity-Relationship Model-Toward a Unified View of DataTODS 1976
D. Harel, "Statecharts: A Visual Formalism for Complex Systems", (1987)
![Page 10: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/10.jpg)
Outlook (by Gartner 2010)
• Key Findings in MDE– The complexity of new, service-oriented
architectures (SOAs) and business process management (BPM) demand more-abstracted, model-driven approaches.
– Business and IT modeling standards and technologies are converging.
– The differences between design time and runtime technologies are disappearing
![Page 11: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/11.jpg)
Modeling convergence
![Page 12: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/12.jpg)
Outlook (by Gartner 2010)
• Recommendations– Ensure collaboration among the IT organization,
business process architects and the analysts who are using these models;
– Use multiple methodologies and approaches to Application Development — especially those that leverage modeling efforts, agile methods, and reusable design patterns and frameworks to improve productivity, while ensuring quality and performance.
– Implement the role of application architect to promote reusable software and data services.
![Page 13: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/13.jpg)
Economic Value (BPM)
![Page 14: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/14.jpg)
MDA: The Modern Age of MDE
• Object Management Group (OMG) unified several modeling languages into a coherent proposal (MDA= Model Driven Architecture) setting the stage for a convergence of architecture, languages, notations, and tools
• UML is the most popular ingredient of MDA but not the only one
![Page 15: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/15.jpg)
MDD, MDA, MDE
MODEL DRIVEN
ARCHITECTURE
MODEL DRIVEN DEVELOPMENT
MODEL DRIVEN ENGINEERING
MODEL DRIVEN TESTING
MODEL DRIVEN COST ESTIMATION
MODEL SEARCH
![Page 16: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/16.jpg)
History
• 1989: OMG formed to create a standard for distributed object systems
• 1991: Corba 1.0 specification released• 1996: OMG includes modeling as a focus• 1997: UML adopted by OMG• 2001: OMG adopts MDA• 2005: UML 2.0 adopted by OMG• 2006: BPMN standard adopted by OMG• 2009: BPMN 2.0 beta 1
![Page 17: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/17.jpg)
OMG MDA standards
• OMG Standards– Modeling – UML– Metamodeling – MOF– Action semantics– Model interchange – XMI– Human-usable textual notation – HUTN– Model-based testing and debugging– Domain-specific UML profiles
![Page 18: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/18.jpg)
MDA core concepts
• System = the subject: a program, a single computer system, some combination of parts of different systems, a federation of systems, each under separate control, people, an enterprise, a federation of enterprises…
• Problem space (Domain): the context where the system operates
• Solution Space: the spectrum of possible solutions that satisfy the system requirements
• Model: a (partial or total, abstract or concrete) representation of the system and its environment
![Page 19: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/19.jpg)
MDA core concepts
• Architecture = specification of the parts and connectors of the system and the rules for the interactions of the parts using the connectors
• Viewpoint: description of a system that focuses on particular concerns
• View: a model of a system under a specific viewpoint
• Transformation: the conversion of a model into another model
![Page 20: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/20.jpg)
MDA core concepts
• Platform: set of subsystems and technologies that provide a coherent set of functionality through interfaces and specified usage patterns (e.g., JEE, .NET)
• Platform Model: a set of technical concepts, representing the different parts that make up a platform and the services provided by that platform
![Page 21: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/21.jpg)
Development
• In MDA development is a chain of transformations from model to model, until enough “concreteness” is incorporated to make the model “executable”
![Page 22: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/22.jpg)
How are models specified
• M0: a concrete system, your application
• M1: the model of your system
• M2: the concepts used to represent your models (e.g., UML or BPMN metamodels)
• M3: the formalism that dicates the rules for defining modeling languages (e.g., UML metamodel expressed in Meta Objet Format-MOF)
M3: meta-meta-model
M2: meta-model
M1: model
M0: system
describes
describes
describes
describes
![Page 23: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/23.jpg)
Example
Customer_table Order_table
customer order
system
model
metamodel
![Page 24: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/24.jpg)
Why meta-models
• Allow a syntactically precise definition of modeling languages
• Can be read by tools, enable portability, model parsing (syntactic) checking
• Like grammars for textual languages and ontologies for semantic languages
The WebML metamodel(fragment)
![Page 25: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/25.jpg)
Classes of models (viewpoints)
• Computation Independent Models: represent the business view of the system
• Platform Independent Models: represents the system abstracting from technology
• Platform Specific Models: represents the system considering technology
CIM
PIM
PSM
mapping
mapping
![Page 26: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/26.jpg)
CIM: examples
• Business Process Modeling Notation: – BPMN provides a
Business Process Diagram (BPD), which is a Diagram designed for use by the people who design and manage business processes.
![Page 27: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/27.jpg)
PIM: examples• Production Rule Representation
(PRR)– a standard production rule
representation that is compatible with rule engine vendors' definitions of production rules
• Product Lifecycle Management Services (PLM)
– a PIM for Product Lifecycle Management Services derived from the ISO 10303-214 STEP model
• Gene Expression (GENE)– representation of gene expression data
and relevant annotations, as well as mechanisms for exchanging these data
• General Ledger (LEDG)– interfaces and their semantics to
enable interoperability between General Ledger systems and accounting applications
![Page 28: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/28.jpg)
Model Transformations
• The application of mapping rules and knowledge to a source model to obtain a target model
• Can use different styles, based on how the mapping rules are specified
Source model
Target model
Additional information
DesignPatterns
Transformation
![Page 29: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/29.jpg)
In this Course
• Business process
Modeling Notation
(BPMN 2.0)
• Web Modeling
Language (WebML)
• Java enterprise
Edition (JEE)
CIM
PIM
PSM
mapping
mapping
![Page 30: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/30.jpg)
Domain Specific Languages (DSL)
• DSL: a language for describing systems in a specific domain (Web apps, embedded systems, etc)
• General Purpose Language: a language for describing systems in multiple domains (e.g., UML)
![Page 31: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/31.jpg)
MDA and DSL
• MDA offers two standard ways to define DSLs
• Stereotyping: UML 2.0 elements are overloaded with domain specific meaning
• Metamodelling: new language constructs are defined
![Page 32: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/32.jpg)
GPL vs DSL
• GPL– (Often) Standard– Portable across tools– More complex– Less intuitive to learn– Lack of precise semantics– Harder to use for code
generation
• DSL– Easier to learn for domain
experts– More precise semantics,
better checking– More amenable to
optimized code generation– Narrower scope– Non standard– Less portable across tools
![Page 33: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/33.jpg)
GPL: UML
• A concrete syntax for specifying any kind of system
• Customizable with extension mechanism (family of languages: Real-Time UML, UML for EDOC..)
• Supported by tools
![Page 34: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/34.jpg)
UML structure
UML INFRASTRUCTURE
MOF
PR
OF
ILES
OCL
ST
AT
E
MA
CH
INE
S
CLA
SS
ES
& C
OM
PO
NE
NT
S
AC
TIV
ITIE
S
INT
ER
AC
TIO
NS
AC
TIO
NS
FLO
WS
BASIC UML
Basic level
Intermediate level
Complete level
![Page 35: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/35.jpg)
DSL: forms
![Page 36: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/36.jpg)
DSL: examples
DSL Application Domain
BNF (1950! ) Syntax Specification
HTML Hypertext Web Pages
MATLAB Technical Computing
SQL Database Queries
LaTex Text processing
Marjan Mernik, University of Maribor
Jan Heering, CWI
Anthony M. Sloane, Macquarie University
ACM Computing Surveys, Vol 37, No. 4
![Page 37: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/37.jpg)
Executability of DSL
• Well-defined execution semantics – HTML
• Input language of an application generator– WebML: Web/SOA modeling– Application generator compiles the DSL into a GPL (Java)– More declarative, well-defined execution semantics
(StateCharts)• Not executable but useful for application generation
– BNF: purely declarative, but can be an input language for a parser generator
• DSL not meant to be executable– Domain-specific data structure representations– Benefit from editors, analyzers, consistency checkers
![Page 38: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/38.jpg)
Language levels (Caper Jones)
Language Level Relationship to Productivity
LANGUAGE LEVEL PRODUCTIVITY AVERAGE PER STAFF MONTH -------------------------- ------------------------------------------------------------------ 1 - 3 5 to 10 Function Points 4 - 8 10 to 20 Function Points 9 - 15 16 to 23 Function Points 16 - 23 15 to 30 Function Points 24 - 55 30 to 50 Function PointsAbove 55 40 to 100 Function Points EXCEL
MATHCAD
![Page 39: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/39.jpg)
Visual DSLsDomain
IdeaFinishedProduct
So
lve
pro
ble
m in
dom
ain
term
sAssembler
Map to code, implement
UML ModelMap to UML
Generate,Add bodies
ComponentsDSVLModel
Generate callsto components
No map!
CodeMap to code, implement
Framework for Domain-Specific Visual LanguagesJuha-Pekka Tolvanen, Steven Kelly, Jeff Gray, Kalle Lyytinen
OOPSLA workshop on DSVL
![Page 40: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/40.jpg)
Visual DLS design and implementation
DomainIdea
FinishedProduct
ComponentsDSVLModel
Generate callsto components
Easy!
Expert(few)
Normal(many)
Codegeneration
DSVLmetamodel
Componentlibrary
![Page 41: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/41.jpg)
Meta CASE for DSVL design
Concepts Symbols
GeneratorsRules1 2 3 4
![Page 42: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/42.jpg)
MDA and Tools
Metamodels
MODELS
Reverse engineering
Import & Export
Textual model Editor
Visual Model Editor
Model Checker
Teamwork
M2M M2text
OTHER MODELS
SOURCE CODE
Metamodel editors
![Page 43: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/43.jpg)
References• Peter Pin-Shan Chen "The Entity-Relationship Model: Toward a Unified
View of Data" ACM on Database Systems, Vol. 1, No. 1, March 1976• Chen, Peter P., Entity-Relationship Modelling: Historical Events, Future
Trends, and Lessons Learned, Springer-Verlag New York, Inc, 2002, pp. 296-310
• D. Harel, "Statecharts: A Visual Formalism for Complex Systems", Sci. Comput. Programming 8 (1987), 231-274.
• J, Rambaugh, Object-Oriented Modeling and Design. With others. Prentice Hall, ISBN 0-13-629841-9, 1991
• G. Booch, Object-Oriented Analysis and Design with Applications. Benjamin Cummings, 1991 (2° Edition 1994, Addison Wesley)
• I. Jacobson, Object-Oriented Software Engineering: A Use Case Driven Approach (ACM Press) With Magnus Christerson, Patrik Jonsson & Gunnar Overgaard. Addison-Wesley, 1992, ISBN 0-201-54435-0, 1992
• I. Jacobson, Grady Booch & James Rumbaugh, The Unified Software Development Process. Addison-Wesley Professional, 1999, ISBN 0-201-57169-2, 1999
![Page 44: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/44.jpg)
References
• Frankel. “Model Driven Architecture: Applying MDA to Enterprise Computing.” Wiley, 2003
• MDA Guide– www.omg.com/mda
• Marjan Mernik, Jan Heering, Anthony M. Sloane: When and how to develop domain-specific languages. ACM Comput. Surv. 37(4): 316-344 (2005)
• Jeff Gray, Kathleen Fisher, Charles Consel, Gabor Karsai, Marjan Mernik, Juha-Pekka Tolvanen: DSLs: the good, the bad, and the ugly. OOPSLA Companion 2008: 791-794
• Juha-Pekka Tolvanen, Steven Kelly, Jeff Gray, Kalle Lyytinen, Framework for Domain-Specific Visual Languages, OOPSLA WS on DSVL 2001
![Page 45: Web technologies: Model Driven Engineering](https://reader033.fdocuments.us/reader033/viewer/2022061115/5462d1d3af79594d4d8b6d28/html5/thumbnails/45.jpg)
References
• Wynn, Moe T. and Verbeek, H.M.W. and van der Aalst, Wil M. and ter Hofstede, Arthur H.M. and Edmond, David (2007) Business Process Verification - Finally a Reality! Business Process Management Journal.
• Johan den Haan, Model Driven Engineering, http://www.theenterprisearchitect.eu/archive/2009/01/15/mde---model-driven-engineering----reference-guide
• Mike Blechar, David Norton , Trends in Model-Driven Development, 4Q09-3Q10, Gartner