modelling for maintainability - university of birmingham · modelling for maintainability. ......

31
Andrew Watson OMG Technical Director Modelling for Maintainability

Upload: doandang

Post on 06-Sep-2018

220 views

Category:

Documents


0 download

TRANSCRIPT

Andrew WatsonOMG Technical Director

Modelling for Maintainability

Modelling for MaintainabilityCopyright © 2011, Object Management Group. All rights reserved. 22 Nov 2011

2

• A successful forum for creating open integration standards in the computer industry- Platforms: BPMN, SBVR, UML, CORBA & related work- Domain: Finance, C4I, Healthcare, etc.

• An industrial consortium with vendor and user members- Implementation must be available from OMG member

• Interfaces freely available to all- Visit http://www.omg.org

• Decisions taken by members

Introducing OMG

Modelling for MaintainabilityCopyright © 2011, Object Management Group. All rights reserved. 22 Nov 2011

AdaptiveAppianAgile BirdsAtegoAtos OriginAxwayBAE SystemsBoeingCACamundaCapgeminiCordysCSC

Darmstadt U.Deere & Co.EADSEclipse Fndn.EFFEPFLFujitsuG. DynamicsGnome Fndn.HDMAHPHitachiIBM

INRIAIntalioJARALockheedMathworksMayo ClinicMEGAMicrosoftMentor GʼicsMITRENARANASANEC

NISTNokiaNorthropNTT DataObjektumOpen GroupOraclePhastPrismTechProgress s/wRaytheonRolls-RoyceRTI

Saab Sys.SAPSofteamSoftware AGSparxSWIFTThalesToshibaU. FrankfurtUnisysW3CWells Fargo(300+ more)

3

Worldwide Membership

Modelling for Maint.Copyright © 2009, Object Management Group. All rights reserved. 24 Nov 2009

4

© Photo copyright Bristol Aeroplane Company/Rolls-Royce

Modelling for MaintainabilityCopyright © 2011, Object Management Group. All rights reserved. 22 Nov 2011

Mechanical design• For 180 years (1800 to c.1980) all mechanical design

documented by draftsmen creating three-view drawings- With ruler, square, protractor, pencils, compass, “french

curve”- ... and eraser- Precise scale drawings; slow, laborious, error-prone- Design revisions involve reworking multiple drawings

• Drawings translated into parts by machinists and fitters- Milling, drilling & turning parts from blanks and castings- Design errors possibly not found until manufacture- Translation errors during fabrication also possible

5

Modelling for Maint.Copyright © 2009, Object Management Group. All rights reserved. 24 Nov 2009

6

Modelling for Maint.Copyright © 2009, Object Management Group. All rights reserved. 24 Nov 2009

7

Modelling for Maint.Copyright © 2009, Object Management Group. All rights reserved. 24 Nov 2009

8

© Photo copyright Bristol Aeroplane Company/Rolls-Royce

Modelling for Maint.Copyright © 2009, Object Management Group. All rights reserved. 24 Nov 2009

9

Modelling for MaintainabilityCopyright © 2011, Object Management Group. All rights reserved. 22 Nov 2011

Computer Assistance• Early Computer-Aided Design (CAD) programs helped with

the production & storage of 2-D drawings

• In 1968 Donald Welbourn of Cambridge University Engineering Dept. saw that computers could store 3-D design models- Can be still be rendered as familiar 2-D 3-view drawing ...- ... but can also generate “program” for CNC machine tools- Real parts automatically created directly from solid models- Computer can also check weight, behaviour of part when

loaded or heated, simulate assemblies (“soft prototyping”)

• Computer-Aided Milling (later Manufacturing) was born

10

Modelling for MaintainabilityCopyright © 2011, Object Management Group. All rights reserved. 22 Nov 2011

CAD/CAM• CUED began experimenting with numerically-controlled

machine tools bought with government grant- But funding a continuing problem

• First public CAM demonstration August 1972, London- Hayes milling machine at Machine Tool Exhibition cut a

“jug- shaped object” directly from a DUCT CAD/CAM design

• Today, CAD/CAM has revolutionised engineering design- One-off, short-run & machined fabrication faster, cheaper,

less error-prone than 20 years ago

11

Modelling for Maint.Copyright © 2009, Object Management Group. All rights reserved. 24 Nov 2009

12

Modelling for Maint.Copyright © 2009, Object Management Group. All rights reserved. 24 Nov 2009

13

Modelling for Maint.Copyright © 2009, Object Management Group. All rights reserved. 24 Nov 2009

14

Modelling for MaintainabilityCopyright © 2011, Object Management Group. All rights reserved. 22 Nov 2011

MDA: Computer-Aided Manufacturing for IT• Most IT shops in similar state to 1980s mechanical engineers

- We now have an agreed diagram syntax for software (UML)- 80% of software designs documented with UML diagrams

representing different views of the required system- UML tools convenient for drawing & erasing diagram lines ..- ... but many programmers turn diagrams into code by hand

• MDA & MDD tools store the equivalent of a CAM solid model- Design can be viewed as UML diagrams ...- ... but tools check correctness & internal consistency ...- ... and fabricate (parts of) the actual system from the model

15

Modelling for Maint.Copyright © 2009, Object Management Group. All rights reserved. 24 Nov 2009

16

Modelling for Maint.Copyright © 2009, Object Management Group. All rights reserved. 24 Nov 2009

17

Modelling for MaintainabilityCopyright © 2011, Object Management Group. All rights reserved. 22 Nov 2011

An MDA Case Study (1)• Parallel development of 2 parts of Central Reservation System

- “Campus” team built Billing & Booking subsystem- “Pricing” team built subsystems handing Products,

Packaging, Pricing, Taxes, Discounts

• WebSphere (J2EE) running on AS/400 with DB2 database- 500K LOC (not including GUI, SQL, conversion or

integration code)- Mostly Java, plus other languages for external integration

• Archuation MDA tool, used with Rational Rose

18

Modelling for MaintainabilityCopyright © 2011, Object Management Group. All rights reserved. 22 Nov 2011

An MDA Case Study (2)• Pricing subsystem 31% of the total classes, 26% of total LOC

- But delivered at only 13% of total cost- Each LOC produced for 50% effort of traditional approach

• Pricing subsystem responsible for 9% of defects found at test- 132 vs. 1291 defects for Campus subsystem- 26% LOC but 9% defects = 1/3 the error rate- Six times as effective (effectiveness = productivity x

quality)

• “The MDA approach may have reduced development costs up to 75% compared to the traditional approach (in this case study)”

19

Modelling for MaintainabilityCopyright © 2011, Object Management Group. All rights reserved. 22 Nov 2011

But ...• The price of software is tiny relative to Total Cost of

Ownership- It has little impact to the outcome of IT investment

decisions

• The price of software is historically less than 10% of TCO- Regardless of Build or Buy

• Up to 70% of TCO is post-implementation- Training, Maintenance, Enhancements, Administration- These costs are largely determined by system quality

• Optimising on the development cost yields a one time benefit - Much better to optimise the post-implementation costs

20

Modelling for MaintainabilityCopyright © 2011, Object Management Group. All rights reserved. 22 Nov 2011

Software “maintenance”• In hardware engineering, “maintenance” means keeping

something in its original state

• According to ISO/IEC 14764, “software maintenance” means:- Fixing design flaws (Corrective & Preventive maintenance)- Modification for new uses (Adaptive maintenance)- Improving performance (Perfective maintenance)

• Arguably, “maintenance” is the wrong word for any of this- Software “maintenance” is actually post-deployment design

21

Modelling for MaintainabilityCopyright © 2011, Object Management Group. All rights reserved. 22 Nov 2011

Software “maintenance” very costly• More than 50% of staff time spent on maintenance

Leintz & Swanson 1980 survey of 487 organisations

• Other maintenance & evolution cost estimates even higher

> 90% Erlikh, 2000

75% Eastwood, 1993

> 90% Moad, 1990

60 – 70% Huff, 1990

76% Jones, 2005

22

Modelling for MaintainabilityCopyright © 2011, Object Management Group. All rights reserved. 22 Nov 2011

New software development techniques that donʼt reduce “maintenance” costs are, at

best, irrelevant to software costs

At worst, theyʼre part of the problem

Cutting development costs in half reduces TCO by ... 5%

Cutting development costs by 20% but increasing “maintenance” costs by 5% actually increases TCO

23

Modelling for MaintainabilityCopyright © 2011, Object Management Group. All rights reserved. 22 Nov 2011

More “maintenance” data• About 250bn lines of source code under “maintenance”

Sommerville, 2000

• US annual software “maintenance” cost > $70bnSutherland 1995, Edelstein 1993

• “Maintainers” spend half their time understanding the codeStandish, 1984

• Volume of code being “maintained” doubles every 7 yearsMüller et al, 1994

24

Modelling for MaintainabilityCopyright © 2011, Object Management Group. All rights reserved. 22 Nov 2011

Technology churn• New delivery technologies arrive every 5-10 years

- Often an improvement (e.g. Java vs. C++)

• But critical IT systems live 25+ years- Worldwide, CICS transaction rate ~= WWW page hit rate- In 2008 Credit Suisse had > 32 MLOC of PL/I in use (vs. 11

MLOC Java)- Ovum estimates > 200,000 MLOC of COBOL in use (2005)

• We can no longer afford to pretend that todayʼs delivery platform is the last one thereʼll ever be- We must stop investing all our intellectual capital in code- That investment too difficult to withdraw when itʼs time to

change platforms25

Modelling for MaintainabilityCopyright © 2011, Object Management Group. All rights reserved. 22 Nov 2011

How to cope?• Rising costs of “maintenance” of a huge, growing software

legacy means we cannot carry on as we have in the past- Cost of keeping old code in service rises to meet budget

• A different approach is needed, recognising that “maintenance” is actually design work- Re-design to fix design errors (Corrective maintenance)- Re-design to serve new purposes (Adaptive maintenance)- Re-design to run on new platforms (Adaptive maintenance)- Re-design for better performance (Perfective maintenance)

• It then becomes obvious that we must apply modern model-driven software design techniques to “maintenance”

26

Modelling for MaintainabilityCopyright © 2011, Object Management Group. All rights reserved. 22 Nov 2011

Middleware Company MDA study• Two parallel implementations of Sunʼs Pet Store sample app

- Sunʼs illustration of “Java Blueprints” design patterns- Typical 3-tier DB/Java/HTML e-commerce application

• Two 3-person teams, “traditional” Java tools vs. OptimalJ

• MDA team completed in 330 man-hours, “traditional” in 508- 35% effort saving, despite learning MDA tool on the job- MDA team estimated they would be 10-20% faster next time

• Level of bugs found during the testing process was higher for the traditional IDE team than the MDA-tool team

27

Modelling for MaintainabilityCopyright © 2011, Object Management Group. All rights reserved. 22 Nov 2011

Middleware Company maintenance report• Pair of 2-man teams add new features to existing Petstore

apps- Tracking pet maturation- Calculating shipping costs- Soliciting supplier bids for new inventory- Integrating with Amazon.com via its web service- Integrating with mainframe application to track shipments

• Traditional team took 260 hours, MDA team 37% less (165 hrs)

• MDA advantage greatest for disruptive changes (pet maturation), break-even for smallest updates (shipping costs)

28

Modelling for MaintainabilityCopyright © 2011, Object Management Group. All rights reserved. 22 Nov 2011

Summary• Model-driven development delivers better code, faster

- ... in the same way that CAD/CAM delivers better engineering products, faster

- Higher code quality reduces short-term “maintenance” costs

• However, major MDA/MDD benefit comes in the long term- Long-term “maintenance” costs dominate TCO- “Maintaining” applications using design models far easier- Porting to new platforms is easier (or even possible)

• The software industry has for decades behaved as though todayʼs delivery platform is the last one thereʼll ever be- This cannot continue

29

Modelling for Maint.Copyright © 2009, Object Management Group. All rights reserved. 24 Nov 2009

Partial Reference listThe Economics of Software Maintenance in the Twenty First CenturyJones, C.http://www.compaid.com/caiinternet/ezine/capersjones-maintenance.pdf (2006)

Software Engineering (6th Edition)Sommerville, I.Addison-Wesley (2000)

An essay on software reuseStandish, TIEEE Trans. on Soft. Eng. SE-10 (5), 494-497 (1984)

Software maintenance costs (annotated bibliography)Koskinen, JUniversity of Jyväskylä (2010)http://users.jyu.fi/~koskinen/smcosts.htm

Understanding software systems using reverse engineering technologyMüller, H., Wong, K. & Tilley, SProc. ACFAS 1994http://rigi.cs.uvic.ca/downloads/papers/pdf/ ussuret.pdf

Model Driven Development for J2EE Utilizing a Model Driven Architecture (MDA) ApproachThe Middleware Company (2003)http://www.omg.org/mda/mda_files/ MDA_Comparison-TMC_final.pdf

Model Driven Development for J2EE Utilizing a Model Driven Architecture (MDA) Approach –Maintainability AnalysisThe Middleware Company (2003)ftp://ftp.omg.org/outgoing/MDA_Maintainability.pdf

30

Modelling for MaintainabilityCopyright © 2011, Object Management Group. All rights reserved. 22 Nov 2011

Essay Question• What is software maintenance? Describe some of the factors

that influence the cost of maintaining software, and critically analyse the claim that Model-Driven Development techniques, such as MDA, have a positive effect on software maintenance practice.

31