Agile Software Development with the UML - PowerPoint PPT Presentation

1 / 20
About This Presentation
Title:

Agile Software Development with the UML

Description:

Running example: online auction system. Agile use of UML. Technique: ... Running example: online auction system. Several suppliers bid for a single contract ... – PowerPoint PPT presentation

Number of Views:159
Avg rating:3.0/5.0
Slides: 21
Provided by: br9348
Category:

less

Transcript and Presenter's Notes

Title: Agile Software Development with the UML


1
Agile Software Developmentwith the UML
  • Bernhard Rumpe
  • Software Systems Engineering
  • Fakultät für Informatik
  • Technische Universität München
  • 21.10.2002

2
Contents
  • Goals of the proposed approach
  • Running example online auction system
  • Agile use of UML
  • Technique modelling of test cases
  • Technique refactoring
  • Testing components through interfaces
  • Conclusion and outlook

3
Proposed approach
  • Method for
  • small and medium sized projects for a
  • more efficient and flexible development of
    systems in
  • rapidly changing business domains such that
  • a high quality product satisfies the customer
    early
  • Approach through integration of
  • agile method techniques with UML
  • Contributions in this talk
  • modelling tests with the UML
  • refactoring of UML diagrams

4
Running example online auction system
  • Several suppliers bid for a single contract
  • Real-time auctions 2h duration, extensions allow
    to react on competitor bids,
  • Example electrical power for a bank for 12 month
    supply 46 cost reduction
  • Requirements
  • availability, security
  • easy to use,
  • high quality implementation,
  • flexible extensions
  • Limited personal resources available

applet running within a browser
5
Trends in software development
  • Size and complexity of systems continually
    increase
  • Isolated solutions ? company-wide integration ?
    E-Commerce
  • New technologies
  • EJB, XML, .Net, ...
  • Diversification of application domains
  • Embedded systems, business systems,
    telecommunication, mobiles
  • Growing methodological experience how to deal
    with these challenges
  • Agile Methods, e.g, address unstable
    requirements, time-to-market pressure, lean and
    effective development for small projects

6
Our approach UML as central notation
UML
7
How UML is used
8
Benefits of this approach
  • UML code blocks are a full programming language
  • compact
  • diagrams allow a good structuring
  • less redundant information
  • Parameterised code generator
  • generates e.g. access methods
  • adaptable to target platform, frameworks, GUI
  • separation of application logic and platform
    dependent code
  • UML as single language for (analysis,) design,
    implementation and test documents
  • Consistency checks used for critical parts
  • type check, tests, consistency of models

9
How the approach supports agile development
Core characteristics of agility
Improvement through use of UML
Efficiency of the developers
increased through advanced notation tools
Reactivity flexibility to deal with changes
incremental development in yet smaller
cycles
Customer focus
even more rapid feedback
Rely on individuals
Simplicity
refactoring increases extensibility
Quality is an emerging property
10
Typical infrastructure of an automated test
  • Principle use
  • relatively complete object diagram (OD) for test
    data
  • partial OD und OCL as oracle
  • sequence diagram (SD) or Java as test driver

expected result and/or OCL-contract as test
oracle
test data
test driver
SD or Java
OD
OD
object under test

OCL
11
Test invariants with object diagrams and OCL
  • OCL and object diagrams can be mutually
    integrated
  • E.g. object diagrams used as predicates within
    OCL statements

describes type of diagram and gives it a name
0

wTextMessage
content Welcome.
12
Sequence diagram test driver and interaction
description
  • linear structure of an exemplaric system run
  • OCL for property description

SD
copper912 Auction
bidPol BiddingPolicy
timePol TimingPolicy
trigger handleBid(bid)
OCL constraints describe properties during the
test run
test driver
13
Refactoring
  • Refactoring is a technique to
  • improve internal structure / architecture of a
    system, while
  • preserving observable behaviour
  • Refactoring rules
  • series of systematically applicable, goal
    directed steps
  • Powerful through
  • simplicity of piecewise application and
  • flexibility of combination of systematic steps
  • Examples
  • expand method, move attribute,
  • add method parameter, split classes
  • Roots
  • Opdyke/Johnson 1992 had 23 refactorings on C
  • Fowler1999 has 72 refactoring rules shown in Java

14
Principle of refactoring
  • Refactoring is orthogonal to adding functionality
  • An idealised diagram

15
Refactoring example 1
CD
Person
Guest
Bidder
checkPasswd()
checkPasswd()
long ident
  • Pull Up Attribute ident into superclass
    structural generalization
  • Factor Method checkPasswd() and adapt it
  • Preservation of observable behaviour?
  • depends on viewpoint class, component, system

16
Refactoring example 2 changing data structures
A series of steps to apply
6. Simplify compile run tests
17
Test as observation for refactoring
  • Both structure and behaviour are observed by tests

18
Validation of refactorings
  • Observation remains invariant under refactoring

test driver and observer
Observation
Refactoring
System run
Modified system run
  • But structure is likely to change through
    refactorings
  • So use proper abstractions and published
    interfaces for acceptance tests

19
Tests as abstract observation
  • Unit tests check methods, single classes and
    small collaborations
  • they need not be abstract
  • but may become obsolete or need to be changed as
    well when tested element is refactored
  • Acceptance tests capture user input/observation
  • Tests should be as abstract as possible
  • Query-methods instead of direct attribute access
  • more stable when data structure is changed
  • OCL property definitions instead of exact
    description of result
  • descriptive properties allow a range of results
  • Ignoring uninteresting objects and attribute
    values
  • Observations of interesting interactions only
  • sequence diagram need not show all interactions
    of the test
  • Published interfaces

20
Outlook and conclusion
  • Integration of two major trends
  • UML and agile techniques
  • Intelligent use of UML allows to successfully
    improve development
  • Methodical knowledge allows more efficient
    processes
  • tests over documentation and reviews
  • refactoring over big-upfront-design phase
  • agile development with UML instead of plan-driven
    method
  • Practical experience has driven this approach and
    will again be needed to trigger further research
Write a Comment
User Comments (0)
About PowerShow.com