detecting and quantifying different types of self-admitted ... · types(of(self8admi;ed(td(8 ant...

10
Detec%ng and Quan%fying Different Types of SelfAdmi;ed Technical Debt Everton da S. Maldonado and Emad Shihab

Upload: others

Post on 20-Aug-2020

1 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Detecting and Quantifying Different Types of Self-Admitted ... · Types(of(Self8Admi;ed(TD(8 Ant Jmeter ArgoUml JFreeChart Columba Percentage 0 20 40 60 80 100 Design debtRequirement

Detec%ng  and  Quan%fying  Different  Types  of  Self-­‐Admi;ed  Technical  Debt  

Everton  da  S.  Maldonado  and  Emad  Shihab  

Page 2: Detecting and Quantifying Different Types of Self-Admitted ... · Types(of(Self8Admi;ed(TD(8 Ant Jmeter ArgoUml JFreeChart Columba Percentage 0 20 40 60 80 100 Design debtRequirement

Self-­‐Admi;ed  Technical  Debt  Iden%fica%on  

Code  Comments  can  be  used  to  detect  TD  

2  

Comment  Pa2erns  

“probably  a  bug”    “hack”  

“fix  this  crap”  

Self-­‐Admi;ed  Technical  Debt  

“duct-­‐tape”  

Page 3: Detecting and Quantifying Different Types of Self-Admitted ... · Types(of(Self8Admi;ed(TD(8 Ant Jmeter ArgoUml JFreeChart Columba Percentage 0 20 40 60 80 100 Design debtRequirement

Examples of Self-admitted Technical Debt  

3  

Page 4: Detecting and Quantifying Different Types of Self-Admitted ... · Types(of(Self8Admi;ed(TD(8 Ant Jmeter ArgoUml JFreeChart Columba Percentage 0 20 40 60 80 100 Design debtRequirement

Different  Types  of  Technical  Debt    

Technical  debt  is  a  broad  concept:    

What  types  of  TD  are  Self-­‐Admi;ed?  

4  

Requirement  debt  …    

Design  debt  ,    DocumentaBon  debt,    

Page 5: Detecting and Quantifying Different Types of Self-Admitted ... · Types(of(Self8Admi;ed(TD(8 Ant Jmeter ArgoUml JFreeChart Columba Percentage 0 20 40 60 80 100 Design debtRequirement

Case  Study  

5  

5  open  source  Java  projects  (Ant,  ArgoUML,  Columba,  JFreeChart  and  Jmeter)  

606K  +    SLOC  39K      +    Extracted  comments  8k  +            Classes  

Page 6: Detecting and Quantifying Different Types of Self-Admitted ... · Types(of(Self8Admi;ed(TD(8 Ant Jmeter ArgoUml JFreeChart Columba Percentage 0 20 40 60 80 100 Design debtRequirement

Manual  Classifica%on  of  Comments  

Can  a  comment  have  more  than  one    classifica%on?  

6  

There  is  a  possibility.  

The  manual  classifica%on  took  about    95  hours  

Page 7: Detecting and Quantifying Different Types of Self-Admitted ... · Types(of(Self8Admi;ed(TD(8 Ant Jmeter ArgoUml JFreeChart Columba Percentage 0 20 40 60 80 100 Design debtRequirement

Quan%fying  Self-­‐Admi;ed  TD  Comments  

7  

Project   #  of  analyzed  comments  

#  of  self-­‐admi;ed    

TD  comments  

%  of  self-­‐admi;ed  TD  per  project  

Ant   4,140   134   3.2  ArgoUML   9,788   1,653   16.8  Columba   6,569   295   4.4  JFreeChart   4,433   219   4.9  Jmeter   8,163   375   4.6  TOTAL   33,093   2,676   -­‐  

Page 8: Detecting and Quantifying Different Types of Self-Admitted ... · Types(of(Self8Admi;ed(TD(8 Ant Jmeter ArgoUml JFreeChart Columba Percentage 0 20 40 60 80 100 Design debtRequirement

Types  of  Self-­‐Admi;ed  TD  

8  

Ant Jmeter ArgoUml JFreeChart Columba

Perc

enta

ge

020

4060

8010

0

Design debtRequirement debtDefect debtTest debtDocumentation debt

Ant Jmeter ArgoUml JFreeChart Columba

Perc

enta

ge

020

4060

8010

0

Design debtRequirement debtDefect debtTest debtDocumentation debt

Ant Jmeter ArgoUml JFreeChart Columba

Perc

enta

ge

020

4060

8010

0

Design debtRequirement debtDefect debtTest debtDocumentation debt

Ant Jmeter ArgoUml JFreeChart Columba

Perc

enta

ge

020

4060

8010

0Design debtRequirement debtDefect debtTest debtDocumentation debt

Ant Jmeter ArgoUml JFreeChart Columba

Perc

enta

ge

020

4060

8010

0

Design debtRequirement debtDefect debtTest debtDocumentation debt

Ant Jmeter ArgoUml JFreeChart Columba

Perc

enta

ge

020

4060

8010

0

Design debtRequirement debtDefect debtTest debtDocumentation debt

Ant Jmeter ArgoUml JFreeChart Columba

Perc

enta

ge

020

4060

8010

0

Design debtRequirement debtDefect debtTest debtDocumentation debt

Ant Jmeter ArgoUml JFreeChart Columba

Perc

enta

ge

020

4060

8010

0

Design debtRequirement debtDefect debtTest debtDocumentation debt

Page 9: Detecting and Quantifying Different Types of Self-Admitted ... · Types(of(Self8Admi;ed(TD(8 Ant Jmeter ArgoUml JFreeChart Columba Percentage 0 20 40 60 80 100 Design debtRequirement

Examples  of  Self-­‐Admi;ed  TD  

9  

Design  Debt:  “quick  &  dirty,  to  make  nested  mapped  p-­‐sets  work:”      [from  Ant]    

Requirement  Debt:  

Defect  Debt:  “Bug  in  above  method”  -­‐  [from  Jmeter]  

“TODO:  no  methods  yet  for  getClassname”  [from  Ant]  

Page 10: Detecting and Quantifying Different Types of Self-Admitted ... · Types(of(Self8Admi;ed(TD(8 Ant Jmeter ArgoUml JFreeChart Columba Percentage 0 20 40 60 80 100 Design debtRequirement

Take  Home  Messages  

1.  We  found  5  types  of  self-­‐admi2ed  TD.  

2.  3.2%  -­‐  16.8%  of  the  comments  contains  some  type  of  technical  debt.  

3.  Design  and  Requirement  debt  are  the  most  common  types  of  self-­‐admi2ed  TD.  

10