Skip to main content
Log in

An exploratory study of the impact of antipatterns on class change- and fault-proneness

  • Published:
Empirical Software Engineering Aims and scope Submit manuscript

Abstract

Antipatterns are poor design choices that are conjectured to make object-oriented systems harder to maintain. We investigate the impact of antipatterns on classes in object-oriented systems by studying the relation between the presence of antipatterns and the change- and fault-proneness of the classes. We detect 13 antipatterns in 54 releases of ArgoUML, Eclipse, Mylyn, and Rhino, and analyse (1) to what extent classes participating in antipatterns have higher odds to change or to be subject to fault-fixing than other classes, (2) to what extent these odds (if higher) are due to the sizes of the classes or to the presence of antipatterns, and (3) what kinds of changes affect classes participating in antipatterns. We show that, in almost all releases of the four systems, classes participating in antipatterns are more change-and fault-prone than others. We also show that size alone cannot explain the higher odds of classes with antipatterns to underwent a (fault-fixing) change than other classes. Finally, we show that structural changes affect more classes with antipatterns than others. We provide qualitative explanations of the increase of change- and fault-proneness in classes participating in antipatterns using release notes and bug reports. The obtained results justify a posteriori previous work on the specification and detection of antipatterns and could help to better focus quality assurance and testing activities.

This is a preview of subscription content, log in via an institution to check access.

Access this article

Subscribe and save

Springer+ Basic
$34.99 /Month
  • Get 10 units per month
  • Download Article/Chapter or eBook
  • 1 Unit = 1 Article or 1 Chapter
  • Cancel anytime
Subscribe now

Buy Now

Price excludes VAT (USA)
Tax calculation will be finalised during checkout.

Instant access to the full article PDF.

Fig. 1
Listing 1

Similar content being viewed by others

Notes

  1. http://argouml.tigris.org/, http://www.eclipse.org, http://www.eclipse.org/mylyn/, and http://www.mozilla.org/rhino/.

  2. http://argouml.tigris.org/issues

  3. http://javacc.dev.java.net/

  4. http://www.ptidej.net/downloads/experiments/emse10

  5. http://www.eclipse.org/osgi/

  6. http://argouml.tigris.org/servlets/NewsItemView?newsItemID=1675

  7. http://eclipse.org/mylyn/new/new-2.0.html

  8. https://bugzilla.mozilla.org/buglist.cgi?query_format=specific&order=relevance+desc&bug_status=__all__&product=Rhino&content={1.6R3|1.6R4|1.6R5}

References

  • Antoniol G, Ayari K, Di Penta M, Khomh F, Guéhéneuc Y-G (2008) Is it a bug or an enhancement? A text-based approach to classify change requests. In: Vigder M, Chechik M (eds) Proceedings of the 18th IBM centers for advanced studies conference (CASCON). ACM Press, New York, 15 pp

    Google Scholar 

  • Aversano L, Canfora G, Cerulo L, Del Grosso C, Di Penta M (2007) An empirical study on the evolution of design patterns. In: Proc. of the the 6th European software engineering conf. and symp. on the foundations of software engineering. ACM Press, New York, pp 385–394

    Google Scholar 

  • Basili VR, Briand LC, Melo WL (1996) A validation of object-oriented design metrics as quality indicators. IEEE Trans Softw Eng 22(10):751–761

    Article  Google Scholar 

  • Bieman JM, Straw G, Wang H, Munger PW, Alexander RT (2003) Design patterns and change proneness: an examination of five evolving systems. In: 9th international software metrics symposium (METRICS’03). IEEE Computer Society Press, Piscataway, pp 40–49

    Google Scholar 

  • Bois BD, Demeyer S, Verelst J, Mens T, Temmerman M (2006) Does god class decomposition affect comprehensibility? In: Proceedings of the IASTED international conference on software engineering. IASTED/ACTA Press, Calgary, pp 346–355

    Google Scholar 

  • Brown WJ, Malveau RC, Brown WH, McCormick HW III, Mowbray TJ (1998) Anti patterns: refactoring software, architectures, and projects in crisis, 1st edn. Wiley, New York

    Google Scholar 

  • Cartwright M, Shepperd M (2000) An empirical investigation of an object-oriented software system. IEEE Trans Softw Eng 26(8):786–796

    Article  Google Scholar 

  • Chidamber SR, Kemerer CF (1994) A metrics suite for object oriented design. IEEE Trans Softw Eng 20(6):476–493

    Article  Google Scholar 

  • Cohen J (1988) Statistical power analysis for the behavioral sciences. L. Erlbaum Associates, Hillsdale

    MATH  Google Scholar 

  • Conte SD, Campbell RL (1989) A methodology for early software size estimation. Technical Report SERC-TR-33-P, Purdue University

  • Deligiannis IS, Shepperd MJ, Roumeliotis M, Stamelos I (2003) An empirical investigation of an object-oriented design heuristic for maintainability. J Syst Softw 65(2):127–139

    Article  Google Scholar 

  • Deligiannis IS, Stamelos I, Angelis L, Roumeliotis M, Shepperd MJ (2004) A controlled experiment investigation of an object-oriented design heuristic for maintainability. J Syst Softw 72(2):129–143

    Article  Google Scholar 

  • Dhambri K, Sahraoui H, Poulin P (2008) Visual detection of design anomalies. In: Proceedings of the 12th European conference on software maintenance and reengineering, Tampere, Finland. IEEE Computer Society Press, Piscataway, pp 279–283

    Google Scholar 

  • Di Penta M, Cerulo L, Guéhéneuc Y-G, Antoniol G (2008) An empirical study of the relationships between design pattern roles and class change proneness. In: Proceedings of the 24th international conference on software maintenance (ICSM). IEEE Computer Society Press, Piscataway

    Google Scholar 

  • Eaddy M, Zimmermann T, Sherwood KD, Garg V, Murphy GC, Nagappan N, Aho AV (2008) Do crosscutting concerns cause defects? IEEE Trans Softw Eng 34(4):497–515

    Article  Google Scholar 

  • El Emam K, Benlarbi S, Goel N, Rai S (2001) The confounding effect of class size on the validity of object-oriented metrics. IEEE Trans Softw Eng 27(7):630–650

    Article  Google Scholar 

  • Fischer M, Pinzger M, Gall H (2003) Populating a release history database from version control and bug tracking systems. In: Proceedings of the international conference on software maintenance, Amsterdam, Netherlands. IEEE Computer Society Press, Piscataway, pp 23–32

    Google Scholar 

  • Fowler M (1999) Refactoring—improving the design of existing code, 1st edn. Addison-Wesley, Reading

    Google Scholar 

  • Gamma E, Helm R, Johnson R, Vlissides J (1994) Design patterns—elements of reusable object-oriented software, 1st edn. Addison-Wesley, Reading

    Google Scholar 

  • Gyimóthy T, Ferenc R, Siket I (2005) Empirical validation of object-oriented metrics on open source software for fault prediction. IEEE Trans Softw Eng 31(10):897–910

    Article  Google Scholar 

  • Hosmer D, Lemeshow S (2000) Applied logistic regression, 2nd edn. Wiley, New York

    Book  MATH  Google Scholar 

  • Khomh F, Guéhéneuc Y-G (2008) Do design patterns impact software quality positively? In: Proceedings of the 12th conference on software maintenance and reengineering (CSMR). IEEE Computer Society Press, Piscataway

    Google Scholar 

  • Khomh F, Di Penta M, Guéhéneuc Y-G, Antoniol G (2009a) An exploratory study of the impact of antipatterns on class change- and fault-proneness. Technical Report, Ecole Polytechnique de Montreal

  • Khomh F, Di Penta M, Guéhéneuc Y-G (2009b) An exploratory study of the impact of code smells on software change-proneness. In: Proceedings of the 16th working conference on reverse engineering (WCRE). IEEE Computer Society Press, Piscataway

    Google Scholar 

  • Khomh F, Guéhéneuc Y-G, Antoniol G (2009c) Playing roles in design patterns: an empirical descriptive and analytic study. In: Kontogiannis K, Xie T (eds) Proceedings of the 25th international conference on software maintenance (ICSM). IEEE Computer Society Press, Piscataway, 10 pp

    Google Scholar 

  • Khomh F, Vaucher S, Guéhéneuc Y-G, Sahraoui H (2009d) A bayesian approach for the detection of code and design smells. In: Proceedings of the 9th international conference on quality software (QSIC). IEEE Computer Society Press, Piscataway, 10 pp

    Google Scholar 

  • Langelier G, Sahraoui HA, Poulin P (2005) Visualization-based analysis of quality for large-scale software systems. In: Proceedings of the 20th international conference on automated software engineering. ACM Press, New York

    Google Scholar 

  • Lanza M, Marinescu R (2006) Object-oriented metrics in practice. Springer, Berlin

    MATH  Google Scholar 

  • Mantyla M (2003) Bad smells in software—a taxonomy and an empirical study. PhD thesis, Helsinki University of Technology

  • Marinescu R (2004) Detection strategies: metrics-based rules for detecting design flaws. In: Proceedings of the 20th international conference on software maintenance. IEEE Computer Society Press, Piscataway, pp 350–359 (2004)

    Chapter  Google Scholar 

  • Moha N (2008) DECOR: détection et correction des défauts dans les systèmes orientés objet. PhD thesis, Université de Montréal et Université de Lille

  • Moha N, Guéhéneuc Y-G, Meur A-FL, Duchien L (2008a) A domain analysis to specify design defects and generate detection algorithms. In: Proceedings of the 11th international conference on fundamental approaches to software engineering. Springer, New York, pp 276–291

    Google Scholar 

  • Moha N, Hacene AMR, Valtchev P, Guéhéneuc Y-G (2008b) Refactorings of design defects using relational concept analysis. In: Medina R, Obiedkov S (eds) Proceedings of the 4th international conference on formal concept analysis (ICFCA). Springer, New York

    Google Scholar 

  • Moha N, Guéhéneuc YG, Duchien L, Meur AF (2010) DECOR: a method for the specification and detection of code and design smells. IEEE Trans Software Eng 36(1):20–36

    Google Scholar 

  • Munro MJ (2005) Product metrics for automatic identification of “bad smell” design problems in java source-code. In: Proceedings of the 11th international software metrics symposium. IEEE Computer Society Press, Piscataway

    Google Scholar 

  • Olbrich S, Cruzes DS, Basili V, Zazworka N (2009) The evolution and impact of code smells: a case study of two open source systems. In: Third international symposium on empirical software engineering and measurement

  • Oliveto R, Khomh F, Antoniol G, Guéhéneuc Y-G (2010) Numerical signatures of antipatterns: an approach based on b-splines. In: Capilla R, Ferenc R, Dueas JC (eds) Proceedings of the 14th conference on software maintenance and reengineering. IEEE Computer Society Press, Piscataway

    Google Scholar 

  • Riel AJ (1996) Object-oriented design heuristics. Addison-Wesley, Reading

    Google Scholar 

  • Sheskin DJ (2007) Handbook of parametric and nonparametric statistical procedures, 4th edn. Chapman & Hall, London

    MATH  Google Scholar 

  • Simon F, Steinbrückner F, Lewerentz C (2001) Metrics based refactoring. In: Proceedings of the fifth European conference on software maintenance and reengineering (CSMR’01). IEEE Computer Society Press, Piscataway, p 30

    Chapter  Google Scholar 

  • Travassos G, Shull F, Fredericks M, Basili VR (1999) Detecting defects in object-oriented designs: using reading techniques to increase software quality. In: Proceedings of the 14th conference on object-oriented programming, systems, languages, and applications. ACM Press, New York, pp 47–56

    Chapter  Google Scholar 

  • van Emden E, Moonen L (2002) Java quality assurance by detecting code smells. In: Proceedings of the 9th working conference on reverse engineering (WCRE’02). IEEE Computer Society Press, Piscataway

    Google Scholar 

  • Vicinanza S, Mukhopadhyay T, Prietula M (1991) Software-effort estimation: an exploratory study of expert performance. Inf Syst Res 2(4):243–262

    Article  Google Scholar 

  • Vokác M (2004) Defect frequency and design patterns: an empirical study of industrial code. IEEE Trans Software Eng 30(12):904–917

    Google Scholar 

  • Wake WC (2003) Refactoring workbook. Addison-Wesley Longman, Boston

    Google Scholar 

  • Webster BF (1995) Pitfalls of object oriented development, 1st edn. M & T Books, Redwood City

    Google Scholar 

  • Wei L, Shatnawi R (2007) An empirical study of the bad smells and class error probability in the post-release object-oriented system evolution. J Syst Softw 80(7):1120–1128

    Google Scholar 

  • Yin RK (2002) Case study research: design and methods, 3rd edn. SAGE, London (2002)

    Google Scholar 

  • Zimmermann T, Weisgerber P, Diehl S, Zeller A (2004) Mining version histories to guide software changes. In: Proceedings of the 26th international conference on software engineering. IEEE Computer Society Press, Piscataway, pp 563–572

    Chapter  Google Scholar 

  • Zimmermann T, Premraj R, Zeller A (2007) Predicting defects for Eclipse. In: Proceedings of the 3rd ICSE international workshop on predictor models in software engineering. IEEE Computer Society Press, Piscataway

    Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Foutse Khomh.

Additional information

We thank Marc Eaddy for making his data on faults freely available. This work has been partly funded by the NSERC Research Chairs in Software Change and Evolution and in Software Patterns and Patterns of Software.

Rights and permissions

Reprints and permissions

About this article

Cite this article

Khomh, F., Penta, M.D., Guéhéneuc, YG. et al. An exploratory study of the impact of antipatterns on class change- and fault-proneness. Empir Software Eng 17, 243–275 (2012). https://doi.org/10.1007/s10664-011-9171-y

Download citation

  • Published:

  • Issue Date:

  • DOI: https://doi.org/10.1007/s10664-011-9171-y

Keywords

Navigation