A Formalism for Transformational Software Evolution Programming Technology Lab Vrije Universiteit Brussel, Belgium Tom Mens

Slides:



Advertisements
Similar presentations
1 A Graph Rewriting Formalism for Object-Oriented Software Evolution Tom Mens FWO Postdoctoral Fellow Programming Technology Lab Vrije.
Advertisements

Software Project Management
1 Reuse Contracts Patrick Steyaert Programming Technology Lab Vrije Universiteit Brussel WWW:
Practical Business Modeling in the Unified Process Tom Morgan Software Architect, Fidelity National Information Services
SE curriculum in CC2001 made by IEEE and ACM: Overview and Ideas for Our Work Katerina Zdravkova Institute of Informatics
Introduction to Software Evolution and Maintenance
1 Software Testing and Quality Assurance Lecture 28 – Testing Class Hierarchies.
Model Eco-systems Decision Systems Lab University of Wollongong.
Software AutomationMarch Managing the Evolution of Reusable Assets Theo D’Hondt Patrick Steyaert Programming Technology Lab Vrije Universiteit Brussel.
1 Lecture 5 Introduction to Software Engineering Overview  What is Software Engineering  Software Engineering Issues  Waterfall Model  Waterfall Model.
Feb. 23, 2004CS WPI1 CS 509 Design of Software Systems Lecture #5 Monday, Feb. 23, 2004.
© Copyright Eliyahu Brutman Programming Techniques Course.
Introduction to Software Design Chapter 1. Chapter 1: Introduction to Software Design2 Chapter Objectives To become familiar with the software challenge.
Software Reengineering 2003 년 12 월 2 일 최창익, 고광 원.
SEG Software Maintenance1 Software Maintenance “The modification of a software product after delivery to correct faults, to improve performance or.
A Domain-Independent Formalism for Software Evolution Tom Mens Programming Technology Lab Vrije Universiteit Brussel February, 2000.
A Survey of Software Refactoring Tom Mens, Tom Tourwé
EMOOSE Object-Oriented Software Evolution Dr. Tom Mens Programming Technology Lab Vrije Universiteit.
Object-oriented Software Engineering with Reuse Contracts Koen De Hondt, Carine Lucas, Kim Mens, Tom Mens, Patrick Steyaert, Roel Wuyts Programming Technology.
Software School of Hunan University Database Systems Design Part III Section 5 Design Methodology.
Introduction to MDA (Model Driven Architecture) CYT.
SOFTWARE DESIGN AND ARCHITECTURE LECTURE 21. Review ANALYSIS PHASE (OBJECT ORIENTED DESIGN) Functional Modeling – Use case Diagram Description.
Copyright 2002 Prentice-Hall, Inc. Modern Systems Analysis and Design Third Edition Jeffrey A. Hoffer Joey F. George Joseph S. Valacich Chapter 20 Object-Oriented.
Reviewing Recent ICSE Proceedings For:.  Defining and Continuous Checking of Structural Program Dependencies  Automatic Inference of Structural Changes.
EAST-ADL Domain-Model – Overview and Planning – Mark-Oliver Reiser (TUB) AMST Workshop Berlin,
A Novel Approach to Architectural Recovery in Evolving Object- Oriented Systems PhD thesis Koen De Hondt December 11, 1998.
Copyright 2002 Prentice-Hall, Inc. Chapter 2 Object-Oriented Analysis and Design Modern Systems Analysis and Design Third Edition Jeffrey A. Hoffer Joey.
University of Southern California Center for Systems and Software Engineering Model-Based Software Engineering Supannika Koolmanojwong Spring 2013.
Methodology - Conceptual Database Design. 2 Design Methodology u Structured approach that uses procedures, techniques, tools, and documentation aids to.
Lecture 3 Uses Cases Topics UML Use Cases pop quiz Readings: Chapter 3 January 24, 2008 CSCE 492 Software Engineering.
Formal Foundations for Software Evolution Programming Technology Lab Tom Mens
A language to describe software texture in abstract design models and implementation.
Composition of UML Described Refactoring Rules Presented by Chin-Yi Tsai.
Systems Analysis and Design in a Changing World, 3rd Edition
Modeling Component-based Software Systems with UML 2.0 George T. Edwards Jaiganesh Balasubramanian Arvind S. Krishna Vanderbilt University Nashville, TN.
Object Oriented Reverse Engineering JATAN PATEL. What is Reverse Engineering? It is the process of analyzing a subject system to identify the system’s.
Object-Oriented Analysis and Design. Lesson 1: Introduction to Software Engineering.
CS 772: Global Knowledge Networks V. “Juggy” Jagannathan CSEE, West Virginia University.
Deriving Operational Software Specification from System Goals Xin Bai EEL 5881 Course Fall, 2003.
PROC-1 1. Software Development Process. PROC-2 A Process Software Development Process User’s Requirements Software System Unified Process: Component Based.
Object-Oriented Modeling: Static Models. Object-Oriented Modeling Model the system as interacting objects Model the system as interacting objects Match.
Chapter 5: Software Re-Engineering Omar Meqdadi SE 3860 Lecture 5 Department of Computer Science and Software Engineering University of Wisconsin-Platteville.
Formal Methods in Software Engineering Credit Hours: 3+0 By: Qaisar Javaid Assistant Professor.
A Formal Model for Object-Oriented Software Reuse Kim Mens Programming Technology Lab Vrije Universiteit Brussel FNRS MeetingMay 6th, 1997.
Katholieke Universiteit Leuven112 April 2000 Research Topics in Software Evolution Dr. Tom Mens FWO Postdoctoral Fellow Programming Technology Lab Vrije.
1 Technical & Business Writing (ENG-715) Muhammad Bilal Bashir UIIT, Rawalpindi.
Object-Oriented Parsing and Transformation Kenneth Baclawski Northeastern University Scott A. DeLoach Air Force Institute of Technology Mieczyslaw Kokar.
Banaras Hindu University. A Course on Software Reuse by Design Patterns and Frameworks.
February 2000Programming Technology Lab, Vrije Universiteit Brussel Reuse Contracts Managing the evolution of reusable components Dr. Tom Mens Programming.
Reuse Contracts A Historic Overview Dr. Tom Mens Programming Technology Lab Vrije Universiteit Brussel Course OOSE.RC EMOOSE
EMEA Beat Schwegler Architect Microsoft EMEA HQ Ingo Rammer Principal Consultant thinktecture
FFSE 2001 – Workshop Schedule --- MORNING --- 9:30Opening + Welcome 9:402 long presentations (Kahl, García-Cabrera) + discussion 11:00Coffee break 11:30long.
Formal Foundations for Software Evolution Programming Technology Lab Tom Mens
Ontologies Reasoning Components Agents Simulations An Overview of Model-Driven Engineering and Architecture Jacques Robin.
October 19, 1998Doctoral Symposium OOPSLA’98 Kim Mens Intentional annotations for evolving object-oriented software Kim Mens Programming Technology Lab.
2000 Research Overview Dr. Kim Mens Programming Technology Lab Vrije Universiteit Brussel.
4 June 1998, Mulhouse, France > ‘98 International Workshop Tom Mens Carine Lucas & Patrick Steyaert Programming Technology.
Documenting Evolving Software Systems through Reuse Contracts Kim Mens Patrick SteyaertCarine Lucas Programming Technology Lab, Vrije Universiteit Brussel.
Object Design More Design Patterns Object Constraint Language Object Design Specifying Interfaces Review Exam 2 CEN 4010 Class 18 – 11/03.
WonderWeb. Ontology Infrastructure for the Semantic Web. IST WP4: Ontology Engineering Heiner Stuckenschmidt, Michel Klein Vrije Universiteit.
Interface Concepts Modeling Core Team
Security analysis of COM with Alloy
Object-Oriented Software Engineering Using UML, Patterns, and Java,
State Digrams in UML: A Formal Senmatics using Graph Transformations
Transformational Software Evolution by Assertions
Ontology Evolution: A Methodological Overview
A Declarative Evolution Framework for Object-Oriented Design Patterns
AGTIVE Workshop Conditional Graph Rewriting as a Domain-Independent Formalism for Software Evolution Tom Mens Programming Technology Lab Vrije Universiteit.
Public PhD Defense A Formal Foundation for Object-Oriented
Reuse Contracts: Managing the Evolution of Reusable Assets
Presentation transcript:

A Formalism for Transformational Software Evolution Programming Technology Lab Vrije Universiteit Brussel, Belgium Tom Mens

March 2001, Lisbon© Mens Tom, Programming Technology Lab 2 Need better tool support for  version control  e.g. upgrading application frameworks  collaborative software development  software merging  change management  change propagation  change impact analysis & effort estimation  ripple effect ...  evolution at a high level of abstraction  evolution of design patterns, refactorings  architectural evolution ... object-oriented software evolution

March 2001, Lisbon© Mens Tom, Programming Technology Lab 3 Need better tool support for  co-evolution between different phases  maintaining consistency  checking compliance between architecture and design, design and implementation,...  re-engineering of legacy systems  program comprehension  reverse engineering  migration ...  empirical research on software evolution  based on change metrics  predictive models ...

March 2001, Lisbon© Mens Tom, Programming Technology Lab 4 Tool support must be  scalable  applicable to large-scale software systems  “A major challenge for the research community is to develop a good theoretical understanding an underpinning for maintenance and evolution, which scales to industrial applications.” [Bennett&Rajlich 2000]  domain-independent  independent of the programming or modelling language  generally applicable in all phases of the software life- cycle

March 2001, Lisbon© Mens Tom, Programming Technology Lab 5 Our Approach: Reuse Contracts Use graph rewriting to provide a formal foundation for software evolution based on reuse contracts

March 2001, Lisbon© Mens Tom, Programming Technology Lab 6 Reuse Contracts Overview  Benefits of reuse contracts (illustrated with a simple example) 1.Document reuse and evolution 2.Deal with upgrade problems 3.Provide support for software merging 4.Provide support for framework refactoring  Generalising reuse contracts (using formalism of graph rewriting) 1.Apply reuse contracts to different domains  analysis, architecture, design, implementation 2.Scale up reuse contracts to high-level transformations

March 2001, Lisbon© Mens Tom, Programming Technology Lab 7 1. Documenting Reuse DesktopFolder position contents move: add: addMany: SizedFolder add: item size reuse Extension(size, attribute) Refinement(add, size, updates) size =+ item.size

March 2001, Lisbon© Mens Tom, Programming Technology Lab 8 DesktopFolder position contents move: add: addMany: 1. Documenting Evolution evolution Coarsening(addMany, add, invokes) DesktopFolder position contents move: add: addMany:

March 2001, Lisbon© Mens Tom, Programming Technology Lab 9 2. Dealing with Upgrade Problems DesktopFolder position contents move: add: addMany: evolution DesktopFolder position contents move: add: addMany: reuse size not updated when adding many items SizedFolder add: item size size =+ item.size SizedFolder add: item size size =+ item.size

March 2001, Lisbon© Mens Tom, Programming Technology Lab Dealing with Upgrade Problems DesktopFolder position contents move: add: addMany: evolution DesktopFolder position contents move: add: addMany: SizedFolder add: size reuse Coarsening(addMany, add, invokes) Extension(size, attribute) Refinement(add, size, updates) inconsistent operation conflict

March 2001, Lisbon© Mens Tom, Programming Technology Lab 11 Conflict Table 2. Dealing with Upgrade Problems extension refinement coarsening extensionrefinementcoarsening no conflicts inconsistent operations interface conflicts operation capture, unanticipated recursion operation capture, inconsistent operations no conflicts operation capture, inconsistent operations  extension/cancellation: adding/removing an operation or attribute  refinement/coarsening: adding/removing invocation or attribute access  abstraction/concretisation: making an operation abstract/concrete

March 2001, Lisbon© Mens Tom, Programming Technology Lab Support for Software Merging DesktopFolder position contents move: add: addMany: evolution DesktopFolder v1 contents add: addMany: evolution Extension(position, attribute) Extension(move:, method) Coarsening(addMany, add, invokes) Extension(size, attribute) Refinement(add, size, updates) inconsistent operation conflict DesktopFolder v2a contents size add: addMany:

March 2001, Lisbon© Mens Tom, Programming Technology Lab Support for FW Refactoring Refactoring conflict ! Bank Account Loan handles Company SplitClass (Bank,[Bank,Agency]) Agency Account Loan handles BankCompany represents AddClass(Safe) AddAssociation(Bank,Safe) Bank Account Loan handles Company Safe  Need for higher-level evolution transformations  Need for user-defined conflict resolution

March 2001, Lisbon© Mens Tom, Programming Technology Lab 14 Reuse Contract Formalism  Domain-independent formalism  Independent of the target language  Independent of the phase in the life-cycle  Lightweight formalism to facilitate tool support  Represent software artifacts by graphs  Represent software evolution by graph rewriting  Formal characterisation of evolution conflicts

March 2001, Lisbon© Mens Tom, Programming Technology Lab 15 Graphs G Triangle «class» Circle «class» «inherits» intersects «operation» «assoc» center radius «attribute» «aggregation» vertices {3} Point «class»Shape «class» area «operation» circumference «operation» x «attribute» distanceTo «operation» y «attribute» «inherits»  Internal Graph Representation +intersects(c: Circle) -radius Circle +distanceTo(p: Point) -x -y Point Triangle +area() +circumfere() Shape center vertices3  Example: UML class diagram  Node types:  «class»  «attribute»  «operation»  «interface»  Edge types:  «assoc»  «aggregation»  «inherits»  «implements»  «accesses»  «updates»  «invokes»

March 2001, Lisbon© Mens Tom, Programming Technology Lab 16 Type Graph v e node type edge type implements nested operation attribute interface class assoc, aggregation, inherits inherits updates, accesses invokes nested  Used to specify domain-specific constraints Specify extra constraints declaratively

March 2001, Lisbon© Mens Tom, Programming Technology Lab 17 P m R area «operation» radius «attribute» «accesses» G Circle «class» area «operation» «accesses» circumference «operation» radius «attribute» H Circle «class» area «operation» «accesses» circumference «operation» radius «attribute» «accesses» L area «operation» radius «attribute» Graph Rewriting  Used to specify software evolution

March 2001, Lisbon© Mens Tom, Programming Technology Lab 18  Use restricted set of graph productions  AddNode  DropNode  AddEdge  DropEdge  RetypeNode  RetypeEdge  RelabelNode  RelabelEdge Primitive Graph Productions AddEdge (area,radius,«accesses») R area «operation» radius «attribute» «accesses» L area «operation» radius «attribute» DropNode (Triangle.area,«operation») R Triangle L «operation» area Triangle

March 2001, Lisbon© Mens Tom, Programming Technology Lab 19 Primitive Graph Productions evolution reuse DropEdge(addMany, add, «invokes») AddNode(size, «attribute») AddEdge(add, size, «updates») inconsistent operation conflict SizedFolder «class» size «attribute» add: «operation» DesktopFolder «class» position «attribute» contents «attribute» move: «operation» add: «operation» addMany: «operation» DesktopFolder «class» position «attribute» contents «attribute» move: «operation» add: «operation» addMany: «operation» «invokes» «updates»

March 2001, Lisbon© Mens Tom, Programming Technology Lab 20 Syntactic Conflicts P1P1 P 2 = DropNode(area,«operation») P 1 = AddEdge(area,radius,«accesses») P2P2 P1P1 P2P2 Undefined source conflict Syntactic conflict if P 1 and P 2 are not parallel independent G Circle «class» area «operation» circumfere «operation» radius «attribute» «accesses» > G2G2 Circle «class» circumfere «operation» radius «attribute» «accesses» G1G1 Circle «class» area «operation» circumfere «operation» radius «attribute» «accesses»

March 2001, Lisbon© Mens Tom, Programming Technology Lab 21 Syntactic Conflicts  Use a syntactic conflict table  Detect syntactic merge conflicts  in terms of transformation preconditions  compare breaches of application preconditions  Advantages general  does not rely on predefined graph produtions scalable  can be used directly for composite or domain-specific graph productions

March 2001, Lisbon© Mens Tom, Programming Technology Lab 22 Syntactic Conflicts -i+isource (e,v) target (e,v) label (i,L) type (i,T) -source (e,v) -target (e,v) -j  if i=j  if j=e  if j=v  if j=e  if j=v  if i=j  if j=v +j C1 if i=j C2 if e=j  if v=j C3 if e=j  if v=j C4 if i=jC5 if i=jC6 if j=v C7 if j=e C8 if j=v C9 if j=e source (f,w) C10 if (e,v)=(f,w)  if v=w  if (e,v)=(f,w)  target (f,w) C11 if (e,v)=(f,w)  if v=w  if (e,v)=(f,w) label (j,L2) C12 if i=j  type (j,T2) C13 if i=j  -source (f,w) C14 if e=f and v  w  -target (f,w) C15 if e=f and v  w

March 2001, Lisbon© Mens Tom, Programming Technology Lab 23 Semantic Conflicts L1L1 area «operation» radius «attribute» R1R1 area «operation» radius «attribute» «accesses» G Circle «class» area «operation» circumfer «operation» radius «attribute» «accesses» G1G1 Circle «class» area «operation» circumfer «operation» radius «attribute» «accesses» m1m1 AddEdge ( ,area,radius,«accesses») H Circle «class» area «operation» circumfer «operation» radius «attribute» «accesses» «invokes» Pushout construction L2L2 area «operation» circumfer «operation» R2R2 area «operation» circumfer «operation» «invokes» G2G2 Circle «class» area «operation» «accesses» circumfer «operation» radius «attribute» «invokes» Refinement ( ,area,circumference,«uses») m2m2 L area «operation» Pullback construction area «operation»

March 2001, Lisbon© Mens Tom, Programming Technology Lab 24  Based on the formal notion of  pushouts and pullbacks  Fine-grained conflict characterisation  By detecting occurrence of graph patterns in result graph Semantic Conflicts addManyaddsize « updates » « invokes » {added during reuse} {removed during evolution} inconsistent method conflict « class » ? « class » ? « inherits » {added by developer 2} {added by developer 1} cyclic inheritance

March 2001, Lisbon© Mens Tom, Programming Technology Lab 25 Structural Conflicts Refactoring conflict ! Bank Account Loan handles Company SplitClass (Bank,[Bank,Agency]) Agency Account Loan handles BankCompany represents AddClass(Safe) AddAssociation(Bank,Safe) Bank Account Loan handles Company Safe More difficult to detect in a general way  Customise conflict table with user-defined and domain-specific conflict resolution rules

March 2001, Lisbon© Mens Tom, Programming Technology Lab 26 Addressing Scalability  Use assertions to describe productions  preconditions, postconditions, invariants  Use dependencies to address scalability 1.Defining “atomic” composite productions from a production sequence 2.Reordering productions in a sequence 3.Removing redundancy in a production sequence 4.Factoring out commonalities from parallel production sequences 5.Parallellising subsequences

March 2001, Lisbon© Mens Tom, Programming Technology Lab 27 Example ctd. L Bank Account Loan handles   P source( ,3)source( ,3)  +( ,3,4,represents,assoc) +(4,Agency,class) +1, +2, +3, + , +  -4 target( ,1), target( ,1) source( ,4)source( ,4) preconditions invariants R Agency Account Loan handles Bank represents    4 postconditions

March 2001, Lisbon© Mens Tom, Programming Technology Lab 28 Using dependencies  Dependencies can be defined between productions  based on relations between assertions

March 2001, Lisbon© Mens Tom, Programming Technology Lab Composite productions (a) Calculate dependencies between productions in the sequence (b) Calculate pre/postconditions of composite in terms of this information

March 2001, Lisbon© Mens Tom, Programming Technology Lab Reordering productions

March 2001, Lisbon© Mens Tom, Programming Technology Lab Removing redundancy  Simplify a production sequence AddN(4) AddN(3)AddN(4)RelabelN(1,2) AddE( ,3,4) RetypeN(2) DropE( ,3,4) DropN(3) AddN(3)AddN(4)DropN(3) AddN(3)AddN(4)DropN(3) redundant pair reorder redundant pair

March 2001, Lisbon© Mens Tom, Programming Technology Lab Removing Redundancy

March 2001, Lisbon© Mens Tom, Programming Technology Lab Factoring out commonalities  Find commonalities in two parallel sequences, and factor out  facilitates merging and conflict detection

March 2001, Lisbon© Mens Tom, Programming Technology Lab 34 Validation of Reuse Contracts  Industrial case  One base release line  many customisations for  customer applications  Collaborative software development  parallel changes to base release and customisations  Provide support for  customisation, refactoring, upgrading, consolidation x NDR DR WDR 0.1 VTM TV2 WDR 1.0 WDR 2.0

March 2001, Lisbon© Mens Tom, Programming Technology Lab 35 To Do  User-friendly tool support  Perform large-scale experiments  Validate scalability  Look at conflict resolution techniques  Look at structural conflicts (refactoring)  Address co-evolution

March 2001, Lisbon© Mens Tom, Programming Technology Lab 36 Future Research: Co-Evolution  Underlying idea  Keep representation of same software artifact at different levels of abstraction (e.g. design and implementation) synchronised during evolution  Use triple graph grammars refinement abstract layer concrete layer consistent??? evolution