BDTEX: A GQM-based Bayesian approach for the detection of antipatterns

  • Authors:
  • Foutse Khomh;Stephane Vaucher;Yann-Gaël Guéhéneuc;Houari Sahraoui

  • Affiliations:
  • Ptidej Team, DGIGL, ícole Polytechnique de Montréal, Canada and GEODES Lab., DIRO, Université de Montréal, Canada;GEODES Lab., DIRO, Université de Montréal, Canada;Ptidej Team, DGIGL, ícole Polytechnique de Montréal, Canada;GEODES Lab., DIRO, Université de Montréal, Canada

  • Venue:
  • Journal of Systems and Software
  • Year:
  • 2011

Quantified Score

Hi-index 0.00

Visualization

Abstract

The presence of antipatterns can have a negative impact on the quality of a program. Consequently, their efficient detection has drawn the attention of both researchers and practitioners. However, most aspects of antipatterns are loosely specified because quality assessment is ultimately a human-centric process that requires contextual data. Consequently, there is always a degree of uncertainty on whether a class in a program is an antipattern or not. None of the existing automatic detection approaches handle the inherent uncertainty of the detection process. First, we present BDTEX (Bayesian Detection Expert), a Goal Question Metric (GQM) based approach to build Bayesian Belief Networks (BBNs) from the definitions of antipatterns. We discuss the advantages of BBNs over rule-based models and illustrate BDTEX on the Blob antipattern. Second, we validate BDTEX with three antipatterns: Blob, Functional Decomposition, and Spaghetti code, and two open-source programs: GanttProject v1.10.2 and Xerces v2.7.0. We also compare the results of BDTEX with those of another approach, DECOR, in terms of precision, recall, and utility. Finally, we also show the applicability of our approach in an industrial context using Eclipse JDT and JHotDraw and introduce a novel classification of antipatterns depending on the effort needed to map their definitions to automatic detection approaches.