Technical Debt - osbridge

2,058 views

Published on

Technical debt is something that most project teams or independent developers have to deal with – we take shortcuts to push out releases, deadlines need to be met, quick fixes slowly become the standard. In this talk, we will discuss what technical debt is, when it is acceptable and when it isn’t, and strategies for effectively managing it, both on an independent and team level.

Published in: Technology
0 Comments
3 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total views
2,058
On SlideShare
0
From Embeds
0
Number of Embeds
17
Actions
Shares
0
Downloads
39
Comments
0
Likes
3
Embeds 0
No embeds

No notes for slide

Technical Debt - osbridge

  1. 1. Technical Debt Elizabeth Naramore Open Source Bridge June 2011
  2. 2. (Me.)
  3. 3. Technical Debt1. What is it?
  4. 4. Technical Debt2. Why should we care?
  5. 5. Technical Debt3. What do we do about it?
  6. 6. “Shipping first time code is like going into debt. A littledebt speeds development so long as it is paid backpromptly with a rewrite...The danger occurs when the debt is not repaid. Everyminute spent on non-quite-right code counts asinterest on that debt.” --Ward Cunningham, 1992
  7. 7. “Shipping first time code is like going into debt. A littledebt speeds development so long as it is paid backpromptly with a rewrite...The danger occurs when the debt is not repaid. Everyminute spent on non-quite-right code counts asinterest on that debt.” --Ward Cunningham, 1992
  8. 8. “I think that there were plenty of cases where peoplewould rush software out the door and learn things butnever put that learning back into the program, andthat by analogy, was borrowing money thinking thatyou never had to pay it back.... eventually all yourincome goes to interest and your purchasing powergoes to zero.” --Ward Cunningham, 1992
  9. 9. “I think that there were plenty of cases where peoplewould rush software out the door and learn things butnever put that learning back into the program, andthat by analogy, was borrowing money thinking thatyou never had to pay it back.... eventually all yourincome goes to interest and your purchasing powergoes to zero.” --Ward Cunningham, 1992
  10. 10. 1. What is Technical Debt?Code or practicesthat willhinder your progressin the future.
  11. 11. 1. What is Technical Debt?Code or practicesthat willhinder your progressin the future.
  12. 12. 2. Why should we care?Too much technical debtcan cripple your teamor organization.
  13. 13. 2. Why should we care?Too much technical debtcan cripple your teamor organization.
  14. 14. 3. What can we do about it?Easy there, tiger.We’ll get to that.
  15. 15. Where do we find it?
  16. 16. In our own code. For example...
  17. 17. You have technical debt if you have...Untested code.
  18. 18. You have technical debt if you have...Untested code.How much time is wastedwhen changes break stuffand create more bugs?
  19. 19. You have technical debt if you have...Suppressed errors.
  20. 20. You have technical debt if you have...Suppressed errors.(Psst. This doesn’t reallymake the error go away. I’vetried.)
  21. 21. You have technical debt if you have...Confusing code, inconsistencies& workarounds
  22. 22. You have technical debt if you have...Confusing code, inconsistencies& workaroundsHow much time has beenwasted trying to sortthrough spaghetti code?
  23. 23. You have technical debt if you have...Legacy code
  24. 24. You have technical debt if you have...Legacy code.How much time has beenwasted trying to sift throughcruft?
  25. 25. You have technical debt if you have...Code that doesn’t followstandards.
  26. 26. You have technical debt if you have...Code that doesn’t followstandards.Code that is hard to read takestime to read.
  27. 27. You have technical debt if you have...Duplicate code blocks.
  28. 28. You have technical debt if you have...Duplicate code blocks.Good for quilts. Not so goodfor fixing mistakes in code.
  29. 29. In things thataffect our code.For example...
  30. 30. You have technical debt if you have...•Non-existent or improperly used VCS.•Unstable deployment process.•Individual code ownership.•Lack of documentation.•Unshared knowledge.•Third party code that needs updated/patched
  31. 31. Guess what?
  32. 32. We all have it.
  33. 33. Don’t panic.
  34. 34. Sometechnical debt is ok.
  35. 35. It might make sense if...It allows you to hit a deadline.
  36. 36. It might make sense if...It allows you to experiment.
  37. 37. It might make sense if...The code is rarely touched.
  38. 38. It might make sense if...You are coding for reasonableexpectations.
  39. 39. It might make sense if...Your code is at the end of the lifecycle.
  40. 40. This kind of debt is known as prudent technical debt.
  41. 41. So when is debt not ok?
  42. 42. All the other times.
  43. 43. This kind of debt is known as reckless technical debt.
  44. 44. Sometimes we know we are taking shortcuts,but we do it anyway.
  45. 45. This kind of debt is known as deliberate technical debt.
  46. 46. Sometimes we don’t know any better, or the debt is not our fault.
  47. 47. This could come from:•inexperienced team members•changing projectrequirements•post-release retrospectives•security patches or updatesfrom third parties
  48. 48. This kind of debt is known as inadvertent technical debt.
  49. 49. 4 ways to classify technical debt: prudent vs. recklessdeliberate vs. inadvertent
  50. 50. Martin Fowler’s Quadrant
  51. 51. Martin Fowler’s Quadrant
  52. 52. By minimizing deliberatedebt, we can better handle inadvertent debt.
  53. 53. So now that we know what it is, let’s move on.3. What can we do about it?
  54. 54. We tackle our debt with D.E.B.T. (see what I did there?)
  55. 55. Discover Where is ourtechnical debt?
  56. 56. Where is our technical debt?•Ask your developers•Use the list mentioned before•Use software like Sonar
  57. 57. Estimatehttp://sonarsource.org
  58. 58. Sonar
  59. 59. Sonarhttp://nemo.sonarsource.org
  60. 60. SonarApache Jackrabbit:
  61. 61. SonarSonar + Technical Debt Plugin
  62. 62. EstimateHow much is it costing us? The Simple-ish Formula Amount of the “loan” = cost to fix“Interest Rate” = Adverse impact on development
  63. 63. EstimateHow much is it costing us?Determining the “interest rate” is hard. Use estimation techniques that work for you.
  64. 64. Break Down
  65. 65. Break DownWhat do we do with this mass of technical debt? All debt breaks down into 2 categories:1. Debts where we continue to pay interest.2. Debts where we pay on the principal.
  66. 66. Task and Track
  67. 67. Task and TrackThe key is making it visible.
  68. 68. Task and TrackThe key is making it visible.
  69. 69. Task and TrackAdd tasks to bug tracker Add to task board Show progress to all
  70. 70. Paying it Off
  71. 71. Paying it OffFocus on high interest items OR Focus on small tickets
  72. 72. Paying it Off Dedicate time.• Use time right after a release• Tech debt iteration/sprint• Time each day for tech debt• Refactor as you go• Use off-season time• Designated Debt Payer
  73. 73. Paying it OffKeep track of your progress AND communicate to all.
  74. 74. Prevention
  75. 75. Prevention•  Break past habits• Group consensus & commitment• Teach your “children” well• Never file for bankruptcy• Live within your means• Anticipate your needs
  76. 76. A few words about change management.
  77. 77. You should read this.
  78. 78. Change Management
  79. 79. Change Management 1. Direct the rider.
  80. 80. Change Management2. Motivate the elephant.
  81. 81. Change Management 3. Shape the path.
  82. 82. Want to contact me? http://naramore.net/blog @ElizabethN elizabeth@naramore.net Freenode IRC: ElizabethN THANKS! Image used with permission from Martin Fowler

×