Pay Now or Pay More Every Day: Reduce Technical Debt Now!

38
AW2 Concurrent Session 11/7/2012 10:15 AM "Pay Now or Pay More Every Day: Reduce Technical Debt Now!" Presented by: Fadi Stephan Excella Consulting Brought to you by: 340 Corporate Way, Suite 300, Orange Park, FL 32073 8882688770 9042780524 [email protected] www.sqe.com

description

Is your team missing delivery dates? Is your velocity inconsistent from sprint to sprint? Are customers complaining about defects or the time it takes to add new features? These are signs that you are mired in technical debt-a metaphor that describes the long-term costs of doing something in a quick and dirty way and not going back to clean up the mess. Fadi Stephan shares a technical debt management approach to help you make prudent decisions on how much effort to invest in reducing technical debt. Discover ways to measure the quality of your current code base and determine the cost of eventual rework hanging over your system. Learn how to engage executives and get buy-in on a debt removal plan that will improve system design, increase the quality of your code, and return your team to high productivity. If you are burdened with technical debt, the choice is to pay now or continue paying more every day-forever.

Transcript of Pay Now or Pay More Every Day: Reduce Technical Debt Now!

Page 1: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

 

    

AW2 Concurrent Session 11/7/2012 10:15 AM 

       

"Pay Now or Pay More Every Day: Reduce Technical Debt Now!"

   

Presented by:

Fadi Stephan Excella Consulting

       

Brought to you by:  

  

340 Corporate Way, Suite 300, Orange Park, FL 32073 888‐268‐8770 ∙ 904‐278‐0524 ∙ [email protected] ∙ www.sqe.com

Page 2: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

Fadi Stephan Excella Consulting

Fadi Stephan is an agile coach, trainer, and consultant with Washington DC-based Excella Consulting. Fadi has more than twelve years of professional experience as a product manager, project manager, software developer, and consultant in businesses ranging from start-ups to Fortune 500 companies. Since 2006, his focus has been on agile adoption and on transitioning, coaching, and mentoring organizations and teams in agile practices. Fadi is a certified Project Management Professional (PMP) and a Certified Scrum Professional (CSP), founder of the DC Software Craftsmanship user group, and organizer of the DC Scrum user group.

.

 

Page 3: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

1

Managing Technical Debt

Managing Technical Debt

[email protected] @FadiStephan AgileJourneyman.com/2012/05/managing-technical-debt.html

Pay Now or Pay More Every Day – Reduce Technical Debt Now!

Page 4: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

2

About Fadi Stephan

• 15+ years of experience in software development

• Focused on Agile since 2006

• Consultant with Excella

• Founder of the DC Software Craftsmanship User Group

• Organizer of the DC Scrum User Group

What’s Going On?

0

5

10

15

20

25

30

35

40

45

1 2 3 4 5 6 7 8 9 10 11 12

Velocity

Page 5: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

3

Page 6: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

4

Page 7: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

5

Rigidity

Page 8: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

6

Page 9: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

7

Immobility

Viscosity

Page 10: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

8

Deadline

Broken Window

Page 11: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

9

Page 12: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

10

Over Architecting

Bad Design

Page 13: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

11

Poor Skills

Technical Debt

“Shipping first time code is like going into debt. A little debt speeds development so long as it is paid back promptly with a rewrite... The danger occurs when the debt is not repaid. Every minute spent on not-quite-right code counts as interest on that debt.”

- Ward Cunningham

Page 14: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

12

Technical Debt Metaphor

“Neglecting the design is like borrowing money”

“Refactoring, it's like paying off the principal debt”

“Developing slower because of this debt is like paying interest on the loan”

“Every minute spent on not-quite-right code counts as interest on that debt”

Principal

Interest

Technical Debt

Quick and dirty design results in

Page 15: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

13

Page 16: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

14

Trading for Quality

Design Stamina Hypothesis

martinfowler.com/bliki/DesignStaminaHypothesis.html

Page 17: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

15

Which one will you choose?

1. Quick and Dirty

2. Clean

Home or car loan

Page 18: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

16

Technical Debt Quadrant

martinfowler.com/bliki/TechnicalDebtQuadrant.html

Types of Debt

• Unintentional

• Intentional

– Short term & focused

– Short term & unfocused

– Long term

• Only short term focused debt & long term debt are “good” debt

forums.construx.com/blogs/stevemcc/archive/2007/11/01/technical-debt-2.aspx

Page 19: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

17

Page 20: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

18

theagileexecutive.com/category/technical-debt

Page 21: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

19

Technical Debt Management Plan

Register the Debt

Page 22: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

20

As I prudent developer,

I am deliberately taking on technical debt by

so that…

Date: 2/10/2012

Impact: M

Estimate: 3

As I prudent developer,

I want to refactor ….

so that I can repay the technical debt

Estimate: 8

Page 23: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

21

Technical Debt Backlog

Story Dirty Estimate

Clean Estimate

On Going Impact

Date

3 8 H 2/5/2012

… 1 5 M 2/10/2012

… 3 13 L 2/11/2012

Complexity

Code Coverage

Duplication

Rule Violations

Design

Evaluate Code Base

Page 24: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

22

Technical Debt = #items * #hours/item * $/hr

Monetize the Debt

Page 25: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

23

Technical Debt Plugin

Debt(in man days) = cost_to_fix_duplications + cost_to_fix_violations + cost_to_comment_public_API + cost_to_fix_uncovered_complexity + cost_to_bring_complexity_below_threshold + cost_to_cut_cycles_at_package_level

SQALE

Changeability Maintainability Security Reliability Testability Efficiency Portability

Page 26: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

24

sqale.org/wp-content/uploads/2012/04/SQALE-3RD-WS-on-MTD.pdf

Page 27: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

25

Requirement Remediation Details Remediation Function

No commented out blocks

Remove 1 min/occurrence

At least 70% code coverage

Write tests 20 min/per uncovered line

Code overrides both equals and hashcode

Write code and tests 1 hr/occurrence

Sample Remediation Functions

sqale.org/wp-content/uploads/2012/04/SQALE-3RD-WS-on-MTD.pdf

SQALE Pyramid

sqale.org/wp-content/uploads/2012/04/SQALE-3RD-WS-on-MTD.pdf

Page 28: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

26

History

Cost = 2,000,000 Profit=10,000,000 Debt =3,000,000 ROI = (10M – 2M)/ 2M = 400%

theagileexecutive.com/category/technical-debt/

Page 29: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

27

theagileexecutive.com/tag/the-agile-triangle/

3,000,000 2,000,000

10,000,000

ROI = (10M – (2M + 3M))/ 5M = 100%

theagileexecutive.com/tag/the-agile-triangle/

Page 30: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

28

How much debt is too much debt?

Metaphor

• Think of 3 more examples of ways to use the technical debt metaphor

– Analogy 1:

– Analogy 2:

– Analogy 3:

• Do you think the technical debt metaphor works well?

• If not, why?

Page 31: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

29

Paying Down The Debt

Pay debt with high interest rate 1st

Page 32: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

30

Approach

• Have a technical debt reduction sprint immediately after a release

• Have a technical debt reduction sprint once we reach a certain limit

• Rotate dedicated members to work on reducing technical debt

• Dedicate 10% of each sprint to reducing technical debt

• Reduce technical debt by story

Page 33: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

31

Summary

Managing technical debt requires that we make prudent and deliberate decision on

design & quality

Summary

Provide transparency by

1. Registering any new debt

2. Assessing existing debt

Page 34: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

32

Summary

Inspect by

1. Monetizing the debt

2. Establishing a debt limit

3. Monitor trends

Summary

Adapt by

1. Paying down the debt focusing on high interest rate 1st.

2. Starting with what you know. Train for the rest

3. Continuously monitor the debt

Page 35: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

33

AgileJourneyman.com @FadiStephan

Acknowledgement

Robert Martin Martin Fowler Israel Gat Steve McConnell

Page 36: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

34

References

• Design Principles and Design Patterns - Robert Martin

• Design Stamina Hypothesis - martinfowler.com/bliki/DesignStaminaHypothesis.html

• Technical Debt Quadrant - martinfowler.com/bliki/TechnicalDebtQuadrant.html

• The Agile Triangle –

theagileexecutive.com/tag/the-agile-triangle/

• Technical Debt Assessment and Reduction –

theagileexecutive.com/category/technical-debt/

• Technical Debt, Cutter IT Journal October 2010 - www.cutter.com

References

• Technical Debt A Perspective for Manager – www.infoq.com/articles/technical-debt-levison

• Managing Technical Debt - blogs.versionone.com/agile_management/2011/07/11/managing-technical-debt/

• What Testers Can Do About Technical Debt - www.stickyminds.com/sitewide.asp?ObjectId=3629

• Climb Out of Technical Debt – www.ayeconference.com/climboutoftechnicaldebt/

• Don't Live with Broken Windows –

www.artima.com/intv/fixit.html

Page 37: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

35

References

• Technical Debt - forums.construx.com/blogs/stevemcc/archive/2007/11/01/technical-debt-2.aspx

• Sonar – http://www.sonarsource.org/evaluate-your-technical-debt-with-sonar/

• Pay Down your Technical Debt – www.codinghorror.com/blog/2009/02/paying-down-your-technical-debt.html

• SQALE Method For Evaluating Technical Debt – http://www.sqale.org/wp-content/uploads/2012/04/SQALE-3RD-WS-on-MTD.pdf

Pictures

• http://www.flickr.com/photos/49531720@N00/247730111/ • http://www.flickr.com/photos/89306448@N00/2247180420/ • http://www.flickr.com/photos/71962092@N00/2874328851 • http://www.flickr.com/photos/16857236@N03/2429136239 • http://www.flickr.com/photos/tpapi/2765541278/ • http://www.flickr.com/photos/97041449@N00/5261698908/ • http://www.flickr.com/photos/7389424@N05/2351559480/ • http://www.flickr.com/photos/24293932@N00/1144691293/ • http://www.flickr.com/photos/17454738@N00/2245445147/

Page 38: Pay Now or Pay More Every Day: Reduce Technical Debt Now!

9/17/2012

36

Pictures

• http://www.flickr.com/photos/25196025@N00/381877979/ • http://www.flickr.com/photos/25507200@N07/3120849218/ • http://www.flickr.com/photos/39516732@N08/4666623572/ • http://www.flickr.com/photos/64211362@N02/6338814898/ • http://www.flickr.com/photos/66622362@N00/3353570653/ • http://www.flickr.com/photos/23327787@N08/3027534098/ • http://www.flickr.com/photos/37815348@N00/5398908333/ • http://www.flickr.com/photos/51035555243@N01/155589939/