technical debt n.
Download
Skip this Video
Loading SlideShow in 5 Seconds..
Technical Debt PowerPoint Presentation
Download Presentation
Technical Debt

Loading in 2 Seconds...

play fullscreen
1 / 56

Technical Debt - PowerPoint PPT Presentation


  • 245 Views
  • Uploaded on

Technical Debt. CS 510 Software Engineering Supannika Koolmanojwong. Outline. What is Technical Debt? Technical Debt Patterns Technical Debt Calculation & Estimation Technical Debt – Industrial perspective. Technical Debt Example.

loader
I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
capcha
Download Presentation

PowerPoint Slideshow about 'Technical Debt' - odette


An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript
technical debt

Technical Debt

CS 510 Software Engineering

Supannika Koolmanojwong

outline
Outline

What is Technical Debt?

Technical Debt Patterns

Technical Debt Calculation & Estimation

Technical Debt – Industrial perspective

technical debt example
Technical Debt Example

“Guys, we don’t have time to dot every I and cross every t on this release. Just get the code done. It doesn’t have to be perfect. We’ll fix it after we release.”

“We don't have time to reconcile these

two databases before our deadline, so

we'll write some glue code that keeps

them synchronized for now and

reconcile them after we ship.”

Ref: Steve McConnell – ICSE 2013

total cost of ownership
Total cost of ownership

‪www.comindwork.com

  • a financial estimate whose purpose is to help consumers and enterprise managers determine direct and indirect costs of a product or system.
    • including the costs to research, develop, acquire, own, operate, maintain, and dispose of a system
total cost of software ownership
Total Cost of Software Ownership

www.dtbusiness.com

‪newtecharticles.com

potential total cost of ownership
Potential total cost of ownership
  • HW and SW
    • Network
    • Server
    • Workstation
    • Installation & integration
  • Purchasing research
  • Warranties and licenses
  • License tracking - compliance
  • Migration expenses
  • Risks: susceptibility to vulnerabilities, availability of upgrades, patches and future licensing policies, etc.
  • Infrastructure
  • Electricity
  • Testing costs
  • Downtime, outage and failure expenses
  • Diminished performance
  • Security (including breaches, loss of reputation, recovery & prevention)
  • Backup and recovery process
  • Technology training
  • Audit
  • Insurance
  • IT personnel
  • Replacement
  • Future upgrade or scalability expenses
  • Decommissioning
common causes of technical debt
Common causes of technical debt

Business pressures

Lack of process or understanding

Lack of building loosely coupled components (hard-coded)

Lack of documentation

Parallel Development

Delayed Refactoring

http://en.wikipedia.org/wiki/Technical_debt

single system development perspective
Single System Development Perspective

Choices driven by potential

  • Market share
  • Future opportunities
  • Technical debt
  • Cost of failure to provide needed capability
technical debt1

CodeSmell

Deficit programming

Code Debt

Toxic Code

Technical Debt

Software Decay

coined by Ward Cunningham

Design Debt

Technical

Inflation

types of debt m anaging software debt building for inevitable change chris sterling
Types of Debt“Managing Software Debt: Building for Inevitable Change”, Chris Sterling
  • Technical Debt
    • These are activities that a team or team members choose not to do well now and will impede future development if left undone
  • Quality Debt
    • There is a diminishing ability to verify the functional and technical quality of software
  • Configuration Management Debt
    • Integration and release management becomes more risky, complex and error-prone
  • Design Debt
    • The cost of adding features is increasing toward the point where it is more than the cost of writing from scratch.
  • Platform Debt
    • The availability of people to work on software changes is becoming limited or cost-prohibitive.

www.psmsc.com

technical debt2
Technical Debt

“is a measure of how untidy or out-of-date the development work area for a product is”

Not the deferred requirements

http://www.c2.com/cgi/wiki?TechnicalDebt

technical debt3
Technical Debt

http://petdance.com/perl/technical-debt

“I don’t know what happened, I just changed one line”

“We can’t upgrade, It will break”

“We can’t upgrade the code, we don’t have time”

“We can’t upgrade the code, no one understands it”

“Just put in the comment XXX, we will do it later”

“Just put in the TODO comment”

technical debt4
Technical Debt
  • intentional technical debt
    • cost to taking short cuts
  • unintentional technical debt
    • making mistakes
    • Conscious decision to optimize for the “present” rather than the “future”
  • cost of not dealing with these short cuts and mistakes will increase over time. 

Read more: http://www.javacodegeeks.com/2012/02/technical-debt-how-much-is-it-really.html#ixzz1phjvB5A9

slide16

http://pkruchten.files.wordpress.com/2011/10/kruchten-111027-techdebt.pdfhttp://pkruchten.files.wordpress.com/2011/10/kruchten-111027-techdebt.pdf

slide17

http://pkruchten.files.wordpress.com/2011/10/kruchten-111027-techdebt.pdfhttp://pkruchten.files.wordpress.com/2011/10/kruchten-111027-techdebt.pdf

slide18

http://pkruchten.files.wordpress.com/2011/10/kruchten-111027-techdebt.pdfhttp://pkruchten.files.wordpress.com/2011/10/kruchten-111027-techdebt.pdf

slide19

http://pkruchten.files.wordpress.com/2011/10/kruchten-111027-techdebt.pdfhttp://pkruchten.files.wordpress.com/2011/10/kruchten-111027-techdebt.pdf

outline1
Outline

What is Technical Debt?

Technical Debt Patterns

Technical Debt Calculation & Estimation

Technical Debt tool – Industrial perspective

technical debt architecture or the platform technology mistake
Technical DebtArchitecture or the platform technology mistake

Read more: http://www.javacodegeeks.com/2012/02/technical-debt-how-much-is-it-really.html#ixzz1phnGFlUV

Scalability, reliability

Foundations are poorly design

you don’t find out until too late (operations phase)

no choice but to start again or rewrite big chunk to keep it working

technical debt error prone code
Technical DebtError-prone code

Read more: http://www.javacodegeeks.com/2012/02/technical-debt-how-much-is-it-really.html#ixzz1phnGFlUV

http://petdance.com/perl/technical-debt/technical-debt.007.html

“ .. If I change X, it is going to break Y, I think ..”

“ Don’t touch that code, last time we did, we spent a week fixing it…”

20% of the code where 80% of bugs are found

Hard to understand

Dangerous to change because done poorly one in the first place

Not rewriting this code is one of the most expensive mistakes that developers make

technical debt not easily tested
Technical DebtNot easily tested

Read more: http://www.javacodegeeks.com/2012/02/technical-debt-how-much-is-it-really.html#ixzz1phnGFlUV

“ .. I thought we had a test for that ..”

Don’t have good automated tests

Tests keep falling apart when you change the code

Testing costs tend to go up over time as you write more code

technical debt code that mysteriously works
Technical DebtCode that mysteriously works

Read more: http://www.javacodegeeks.com/2012/02/technical-debt-how-much-is-it-really.html#ixzz1phnGFlUV

nobody is sure how or why

Might be written by the geek who left the company

if nobody on the team understands it, it’s a time bomb

technical debt others
Technical DebtOthers

Read more: http://www.javacodegeeks.com/2012/02/technical-debt-how-much-is-it-really.html#ixzz1phnGFlUV

  • Forward and backward compatibility
    • Short term debt
  • Duplicate, copy-and-paste code
    • How many ? Trackable ?
  • Hard coding
  • Out of date documentation
    • “We just lost the drive, where are the backups”
    • If nobody is using it, get rid of it. If people are using it, why isn’t it up to date?
slide26

Development Cost(Perfect World)

% Effort per Phase

Analysis

Test

Integration

Design

Implementation

slide27

Typical Defect Profiles

Classification of Defects

Design

Defects

Implementation

Defects

Integration

Defects

Analysis

Test

Integration

Design

Implementation

Defect Insertion

Defect detection & Removal

slide28

Development Cost(Real World)

% Effort per Phase

Analysis

Test

Integration

Design

Implementation

slide29

Development Cost

% Effort per Phase

Analysis

Test

Integration

Design

Implementation

Real world

Perfect World

slide30

Development Cost

Technical

Debt?

Technical

Debt?

% Effort per Phase

Technical

Debt?

Technical

Debt?

Analysis

Test

Integration

Design

Implementation

Real world

Perfect World

slide31

Development Cost

Technical

Debt?

% Effort per Phase

Technical

Debt?

Analysis

Test

Integration

Design

Implementation

Real world

Perfect World

slide32

COTS Integration

% Effort per Phase

Technical

Debt?

Analysis

Test

Integration

Design

Implementation

Real world

Perfect World

outline2
Outline

What is Technical Debt?

Technical Debt Patterns

Technical Debt Calculation & Estimation

Technical Debt – Industrial perspective

financial debt vs technical debt
Financial debt vsTechnical Debt

http://martinfowler.com/bliki/TechnicalDebt.html

technical debt cost estimation
Technical Debt Cost Estimation

Principal = Repair Effort

Interest = Maintenance Effort

[Nugroho et al 2011]

[Curtis et al 2012]

Ref: Nugroho et al 2011, An Empirical Model of Technical Debt and Interest, MTD 2011

Ref: Curtis e al 2011, Estimating the Principal of an Application's Technical Debt. IEEE Software

slide36

700 applications

  • 158 organizations
  • 357 MLOC
  • No sample less than 10KSLOC

Conservative - Assume all violations would be fixed within one hour

Weighted - varied the hours needed for fixing within each severity category,

More realistic -

based on data observed in several IT

organizations.

Ref: Curtis e al 2011, Estimating the Principal of an Application's Technical Debt. IEEE Software

slide37

Average Technical Debt per LOC = $3.61

Ref: Curtis e al 2011, Estimating the Principal of an Application's Technical Debt. IEEE Software

slide38

Ref: Curtis e al 2011, Estimating the Principal of an Application's Technical Debt. IEEE Software

technical debt within each technology
Technical Debt within each technology

http://www.castsoftware.com/research-labs/technical-debt-estimation

outline3
Outline

What is Technical Debt?

Technical Debt Patterns

Technical Debt Calculation & Estimation

Technical Debt – Industrial perspective

sonar
Sonar

Mainly manage the software quality

SQALE – Software Quality Assessment based on Lifecycle Expectations

nemo an open source tool by sonar http nemo sonarqube org
Nemo - An open source tool – by sonarhttp://nemo.sonarqube.org
sonar sqale plug in http www sonarsource com products plugins governance sqale
Sonar – SQALE plug-inhttp://www.sonarsource.com/products/plugins/governance/sqale/
developers 7 deadly sins
Developers’ 7 Deadly Sins

Bad Distribution of Complexity

Duplications

Lack of Unit Tests

No Coding Standards

Not Enough or Too Many Comments

Potential Bugs

Spaghetti Design

http://docs.codehaus.org/display/SONAR/Developers%27+Seven+Deadly+Sins

developers 7 deadly sins1
Developers’ 7 Deadly Sins

Bad Distribution of Complexity

Duplications

http://docs.codehaus.org/display/SONAR/Developers%27+Seven+Deadly+Sins

developers 7 deadly sins2
Developers’ 7 Deadly Sins

Lack of Unit Tests

No Coding Standards

http://docs.codehaus.org/display/SONAR/Developers%27+Seven+Deadly+Sins

developers 7 deadly sins3
Developers’ 7 Deadly Sins
  • Not Enough or Too Many Comments (time consuming maintenance)
    • Documented complex or not straightforward pieces of code
    • Readable unit tests scenarios that will help the developers understand the code
    • Documented API that will help external developers understand how to use those API
    • Respect of coding standard such as naming conventions
  • Potential Bugs

http://docs.codehaus.org/display/SONAR/Developers%27+Seven+Deadly+Sins

developers 7 deadly sins4
Developers’ 7 Deadly Sins
  • Spaghetti Design
    • Hunting for cycles
    • Checking your own architecture rules
    • Managing your libraries
    • Checking the single responsibility principle with LCOM4 (Lack of Cohesion of Methods)
    • RFC (Response for Class) – checking coupling (complexity of class in terms of method calls)

http://docs.codehaus.org/display/SONAR/Developers%27+Seven+Deadly+Sins

slide49

x

=

=

x

http://www.moovweb.com/blog/technical-debt-infographic/

fixing technical debt
Fixing technical debt

http://www.javacodegeeks.com/2011/11/dealing-with-technical-debt.html#ixzz1pjQ8bQpF

  • Big Bang
    • no new features for a year? Really? 
    • spend some time cleaning up the mess
    • Good ?
  • Dedicated Team
    • Have another team dedicated
    • Good ? 80/20 rule ?
  • Boy Scout
    • remove technical debt little and often
    • If no tests, add some. If poor test, improve them. If bad code, refactor it
    • The boy scout rule – leave the camp cleaner than you found it
fixing technical debt1
Fixing technical debt
  • Think time & risk & $$$
  • No gold-plating
    • Unnecessary task that no one wants
  • BigResearchUpFrontvsBigDesignUpFront
technical debt vs agile bad
Technical Debt vs Agile : Bad

http://www.startuplessonslearned.com/2009/07/embrace-technical-debt.html

  • Quick and dirty approach
  • Scalability vsDoTheSimplestThingThatCouldPossiblyWork
    • Just-in-time Scalability
      • change the architecture in response to actual customer demand
        • Wasted Code
technical debt vs agile good
Technical Debt vs Agile : Good

http://www.startuplessonslearned.com/2009/07/embrace-technical-debt.html

Get feedback faster

Smaller batches

technical debt vs lean good
Technical Debt vs Lean : Good

http://www.startuplessonslearned.com/2009/07/embrace-technical-debt.html

Less waste, less debt

Just-in-time nature

technical debt vs ndi bad
Technical Debt vs NDI : Bad

http://www.startuplessonslearned.com/2009/07/embrace-technical-debt.html

  • Product Development Leverage
    • Your product is fortified by others
      • Open-source, COTS, Services
  • Pros: Faster
  • Cons
    • Code understanding
    • Different coding styles, architecture, quality
    • No direct control