+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
Â
MDE 2.0.: pragmatic model verification and other stories - Habilitation public lecture
1. MDE 2.0 â Pragmatic formal model verification
and other stories
Jordi Cabot
HdR
http://modeling-languages.com
1
2. Index
ï§ Introducing MDE
ï§ Research in MDE
ï§ A Research Agenda for MDE 2.0
â Models & Quality
â Legacy systems
â Social aspects
â Very Large models
ï§ Dissemination and technology transfer
ï§ Credits
ï§ Conclusions
5. Model-driven Engineering
ï§ MDE tries to improve this situation by promoting engineering
principles in Software Engineering
ï§ MDE advocates the rigorous use of software models as the main
artifacts in all software engineering activities.
ï§ This in fact is common practice in many other professions
ï§ Does anybody imagine building a house without plans?
12. Models & Metamodels
A model is the result, of the observation
of a system considering a given
metamodel with specific objectives
or purposes.
System S Metamodel
.
MM
conforms to
representation of
Model M
12
16. Index
ï§ Introducing MDE
ï§ Research in MDE
ï§ A Research Agenda for MDE 2.0
â Models & Quality
â Legacy systems
â Social aspects
â Very Large models
ï§ Dissemination and technology transfer
ï§ Credits
ï§ Conclusions
18. We have advanced a lot on the core techniques
ï§ UML and profiles
ï§ DSLs & Language workbenches
ï§ Model-to-model and model-to-text transformations
ï§ Model management and evolution
ï§ âŠ
19. with some contributions: Conceptual Modeling
J Cabot, R RaventĂłs: Conceptual Modelling Patterns for Roles. Journal on
Data Semantics
20. with some contributions: Rule modeling
J Cabot, E Teniente: Transformation Techniques for OCL Constraints.
Science of Computer Programming Journal
21. with some contributions: Code Generation
Albert, Cabot, GĂłmez, Pelechano: Automatic Generation of Basic Behavior Schemas from
UML Class Diagrams. Software and Systems Modeling
Albert,Cabot, GĂłmez,Pelechano. Generating operation specifications from UML class
diagrams: A model transformation approach. Data & Knowledge Engineering
22. with some personal contributions: Code
Generation
J Cabot, E Teniente: Incremental Integrity Checking of UML/OCL
Conceptual Schemas. Journal of Systems and Software
23. with some contributions: UML Validation
Validate
English Text
Stakeholder
Explains
Transf M2T:
SBVR to Natural
Language
Models UML
CASE Transf. M2M: Structured
English
UML Model SBVR Model
Tool UML to SBVR
Designer RuleSpeak
...
...
J Cabot, R Pau, R RaventĂłs: From UML/OCL to SBVR Specifications:
a Challenging Transformation. Information Systems
24. with some contributions: API integration
J CĂĄnovas, F Jouault, J Cabot, J GarcĂa Molina. API2MoL: Automating
the building of bridges between APIs and Model-Driven Engineering.
Information and Software Technology.
25. But itâs clearly not enough
ï§ Modeling will be commonplace in 3 years time â S. Mellor
Though he is giving the same answer for the last 20 years
26. Index
ï§ Introducing MDE
ï§ Research in MDE
ï§ A Research Agenda for MDE 2.0
â Models & Quality
â Legacy systems
â Social aspects
â Very Large models
ï§ Dissemination and technology transfer
ï§ Credits
ï§ Conclusions
30. Quality
ï§ Quality is a very broad concept
ï§ We focus on the verification of models (are we building the models right?)
and, partially, on their validation (are we building the right models?)
32. A Basic quality property: Satisfiability
ï§ Satisfiability is the most basic correctness property for static models.
Liveliness, redundancy,⊠can be expressed in terms of this one
ï§ A model is satisfiable if it is possible to create a valid instantiation of that
model. Otherwise it is useless, users wonât be able to work with the model
ï§ A instantiation is valid if it satisfies all model constraints
name = âPeterâ
e1: Employee
* WorksIn 1
WorksIn
Employee Dept
name: String
workers dept id: String
1 Boss 0..1
manager managed
id = âHRâ
d1: Dept
Boss
name
33. Example: Is it satisfiable?
2 parent
Person
name: string children
*
+ constraint : Nobody can be his own ancestor
38. Translation of OCL invariants
context Paper inv: self.wordCount < 10000
OperationCallExp
ï§ OCL invariant = <
instance of OCL
metamodel
AttribCallExp IntLiteralExp
ï§ Invariant becomes a wordCount 10000
constraint of the CSP
VariableExp
self
39. Translation of OCL invariants
Result
OperationCallExp
LessThan(Vars, Result):- <
// Evaluate subexpressions
X Y
Attribute(Vars, X),
Constant(Y), AttribCallExp IntLiteralExp
// Compute result wordCount 10000
#<(X,Y, Result). Z
VariableExp
self
40. Translation of OCL invariants
Result
attribute(Vars, X) :-
// Evaluate subexpressions OperationCallExp
self(Vars, Z), <
arg(Z, âwordCountâ, X).
X Y
AttribCallExp IntLiteralExp
wordCount 10000
Z
self(Vars, Z) :- VariableExp
self constant (Y):-
// Z is the only visible var
nth1(1, Vars, Z). Y = 10000.
41. Translation of OCL invariants
context Paper inv: self.wordCount < 10000
invariant(Papers):-
// Expression must be true
// for each Paper
( for (Paper, Papers)
do
LessThan([Paper],Result),
Result #= 1 ) .
42. OCL Prolog library
ï§ To analyze OCL constraints, it is necessary to provide a translation for
all OCL constructs in terms of the Prolog-based language used by the
ECLiPSe solver.
ï§ We have extended ECLiPSe with a new library dedicated to the
translation of OCL constraints
ï§ The library makes use of the ECLiPSe support for higher-order
predicates
e.g. ocl_set_collect(Instances, Vars, Set, Predicate, Result),
ï§ Removal of symmetries and the suspension mechanism are used to
optimize the performance of the library
43. Resolution of the CSP
Define cardinality variables
Constraints on cardinalities
Assign cardinalities
Define attribute variables
Constraints on attributes
Assign attributes
Proof
44. Trade-offs in verification
ï§ Decidability: is automation possible? Yes
ï§ Completeness: proof for any input?
No, bounded verification
(but Small Scope hypothesis â D. Jackson )
ï§ Expressiveness: full OCL support? Yes
ï§ Efficiency: Controlled by the user
ïź Validation is also possible: we can generate valid instances from
partial models
45. Other applications (1): Operation contracts
ï§ Verification of contracts: Applicability and executability of
operations, determinism,âŠ
46. Other applications(2): Graph Transformation to OCL
work
NAC: LHS: RHS:
op1 op2
machine machine machine
context System::work()
LHS
NAC
pre: Machine::allInstances()â>exists(m|
not ( Operator::allInstances()â>exists(op1|m.operatorâ> includes(op1)))
post: Machine::allInstances()@preâ>exists(m| not
( Operator::allInstances@pre()â>exists(op1|m.operator->includes(p1)))
and op2.oclIsNew() and op2.oclIsTypeOf(Operator) and m.operatorâ>includes(op2
RHS
Cabot, ClarisĂł, Guerra, de Lara: A UML/OCL framework for the analysis
of graph transformation rules. Software and System Modeling
47. Other applications(3): TGG / QVT / ATL to OCL
work
{new} {new}
{new} {new}
c :Class c2t :Cl2Tb t :Table
name {new} name
persistent
ATTR COND: c.name=t.name and c.persistent=true
Invariants:
context Cl2Tb Inv:
self.class.size()=1 and self.table.size()=1 and self.class.name=self.table.name
context Class Inv:
self.persistent=true implies self.Cl2Tb.size() >=1
context Table Inv:
self.Cl2Tb.size() >=1
Cabot, Clariso, Guerra, de Lara: Verification
and validation of declarative model-to-model
transformations through invariants. Journal of
Systems and Software
48. Challenges / Work in Progress
ï§ Incremental verification
ï§ Combine CSPs with SMT solvers to provide a complete verification approach
when possible.
ï§ More meaningful feedback (e.g. the subset of constraints that cause the
inconsistency)
ï§ Model slicing for parallel verification
50. MoDISCO: a MDRE framerwork
Modernization
Legacy helpers
Systems âąDocumentation
âąImpact analysis
Source code âąModels
âąViewpoints
Databases
âąRestructured code
âąMigrated code
Configuration
files
âąMetrics
MoDisco âąNorms checking
Eclipse Modeling
ïź Instead of adhoc Rev. Eng. Solutions, we use an intermediate
model-based representation of the legacy system
51. MDRE phases in MoDisco
Discove Understan Transform
r d
Legacy artifacts :
- source code
- configuration files
- tests New
Models Viewpoints
- databases Software Artifacts
- etc.
ï§ Why? Models provide an homogeneous and
interrelated representation of all legacy components.
No information loss: initial models have a 1:1
correspondance with the code
51
52. Challenges / Work in Progress
ï§ Extraction of business rules
â Getting a model of the code helps but itâs still too low-level for a
stakeholder to look at it
â Semi-automatic approach with IBM.
ï§ Rev Eng of the whole software system
â We know how to extract a model from a single component but we
donât take into account its relationship with other components (esp. in
other layers)
â Companies are interested in knowing the enterprise architecture (e.g.
TOGAF) of a system
53. Challenges / Work in Progress
ï§ Reverse Engineering of security policies
55. Social aspects of MDE
ï§ We need a better understanding of the needs of users (technical and non-
technical) to make sure we solve their actual problems (and not the ones
we think they have).
ï§ One example: Huge amount of research on providing methods for the
specification, validation, etc of non-functional requirements:
â Nontechnical constraints (like cost, type of license, specific providers)
are as prominent as technical requirements like performance or security
â Modern technology platforms already cover many applicationsâ quality
requirements so explicit NFR management not so useful
â NFRs are hardly ever documented and poorly validated
Architecture Quality Revisited. Buschmann, Frank; Ameller, David; Ayala,
Claudia P.; Cabot, Jordi; Franch, Xavier. IEEE Software, vol. 29 (4)
57. Collaborative development of DSLs
ï§ Participation of end-users is specially relevant when creating DSLs since we
are creating a language for them
59. Collaborative development of DSLs
ï§ Collaboro: process + DSL + tool to enable the collaborative development of
DSLs
ï§ Users suggest changes to both abstract and concrete syntax levels
ï§ The community comments and votes changes and solutions
ï§ Once an agreement is reached (based on a given decision policy, e.g.
unanimity) the solution is added to the current language version
ï§ We get:
â Languages that better satisfy the usersâ needs
â Traceability to justify the rational behind the language design decisions
60. Challenges / Work in progress
ï§ Gamification techniques to promote more user interaction
ï§ What constitutes a good concrete syntax for DSLs?
ï§ Learning from web designers: AB testing for DSLs
âE.g. evolve the concrete syntax based on which
alternative gets more âconversionsâ).
62. Scalability
ï§ MDE tools fail when dealing with very large models
â E.g. reverse engineering of the Eclipse platform generates a model of
more than 5M instances
â EMF just crashes with these volumes
ï§ Scalability important both at the model (loading very large
models) and model manipulation level (executing complex
transformations on large models)
ï§ Key problem in industrial scenarios but far from a trivial one
â Very Large DataBases is the main conf. in the database domain with
37 editions and still looking for solutions
63. Modeling in the cloud
ï§ Can the Cloud be used to handle VLMs?
ï§ Two key aspects:
â Model storage in the Cloud for efficiently storing and loading VLMs
â Model transformation in the Cloud for distributing the computation of
the transformation
âą Each virtual node executes the full transformation on a subset of
the model
âą Each virtual node executes part of the transformation on the full
model
67. Challenges / Work in Progress
ï§ Optimal way to split the models and transformations
â And when not to split them
ï§ Best technology for the backend?
â Hadoop for storing the models plus MapReduce for the transformations?
ï§ Reactive transformation engine:
â Automaticaly activate only the strictly needed computation in response
to updates or requests of model elements.
â Incremental, minimal set of recalculations
68. Index
ï§ Introducing MDE
ï§ Research in MDE
ï§ A Research Agenda for MDE 2.0
â Models & Quality
â Legacy systems
â Social aspects
â Very Large models
ï§ Dissemination and technology transfer
ï§ Credits
ï§ Conclusions
73. The Modeling Languages portal
ï§ Dissemination of MDE news, tutorials, tools,⊠for people:
â Researchers and practitioners
â Novices or experts
ï§ Goal: to explore and discuss when, where and how MDE
can improve current software engineering practices
ï§ modeling-languages.com
78. Conclusions
ï§ MDE is changing the way we build software
â Though this âweâ is still limited
ï§ We have explored some of the (IMHO) promising research
directions to improve MDE (and its adoption):
â Quality, scalability, human aspects, legacy systems
ï§ MDE as a means to an end ï Better Software Engineering
ï§ It is ok to renounce to perfect solutions in exchange of
useful ones
â The good-enough revolution (Wired â 09/2009)
Hinweis der Redaktion
This is an strange presentation: it is not about the topics you are working in. B
Including many crytical systems
Chaos report 2009
Rigorous= precise semantics
This is an strange presentation: it is not about the topics you are working in. B
To present you a method that helps the designer during the specification of the software system by automatically generating a set of operations for a given class diagram.
Simple is more or less as public
This is an strange presentation: it is not about the topics you are working in. B
To present you a method that helps the designer during the specification of the software system by automatically generating a set of operations for a given class diagram.