A Multi-Site Joint Replication of a Design Patterns Experiment Using Moderator Variables to Generalize across Contexts

Context. Several empirical studies have explored the benefits of software design patterns, but their collective results are highly inconsistent. Resolving the inconsistencies requires investigating moderators—i.e., variables that cause an effect to differ across contexts. Objectives. Replicate a design patterns experiment at multiple sites and identify sufficient moderators to generalize the results across prior studies. Methods. We perform a close replication of an experiment investigating the impact (in terms of time and quality) of design patterns (Decorator and Abstract Factory) on software maintenance. The experiment was replicated once previously, with divergent results. We execute our replication at four universities—spanning two continents and three countries—using a new method for performing distributed replications based on closely coordinated, small-scale instances (“joint replication”). We perform two analyses: 1) a post-hoc analysis of moderators, based on frequentist and Bayesian statistics; 2) an a priori analysis of the original hypotheses, based on frequentist statistics. Results. The main effect differs across the previous instances of the experiment and across the sites in our distributed replication. Our analysis of moderators (including developer experience and pattern knowledge) resolves the differences sufficiently to allow for cross-context (and cross-study) conclusions. The final conclusions represent 126 participants from five universities and 12 software companies, spanning two continents and at least four countries. Conclusions. The Decorator pattern is found to be preferable to a simpler solution during maintenance, as long as the developer has at least some prior knowledge of the pattern. For Abstract Factory, the simpler solution is found to be mostly equivalent to the pattern solution. Abstract Factory is shown to require a higher level of knowledge and/or experience than Decorator for the pattern to be beneficial.

[1]  T. Cook,et al.  Quasi-experimentation: Design & analysis issues for field settings , 1979 .

[2]  Javier Garzás,et al.  Do Rules and Patterns Affect Design Maintainability? , 2009, Journal of Computer Science and Technology.

[3]  Natalia Juristo Juzgado,et al.  Report from the 2nd international workshop on replication in empirical software engineering research (RESER 2011) , 2012, SOEN.

[4]  Walter L. Smith Probability and Statistics , 1959, Nature.

[5]  Paul Diesing,et al.  How does social science work , 1991 .

[6]  Dennis L. Eggett,et al.  Design Patterns in Software Maintenance: An Experiment Replication at Brigham Young University , 2011, 2011 Second International Workshop on Replication in Empirical Software Engineering Research.

[7]  Paul Felt,et al.  Improving the Effectiveness of Machine-Assisted Annotation , 2012 .

[8]  P. Diesing How Does Social Science Work?: Reflections on Practice , 1992 .

[9]  Donald Eugene. Farrar,et al.  Multicollinearity in Regression Analysis; the Problem Revisited , 2011 .

[10]  Shing-Chi Cheung,et al.  Work experience versus refactoring to design patterns: a controlled experiment , 2006, SIGSOFT '06/FSE-14.

[11]  ชวิตรา ตันติมาลา Constructing Grounded Theory: A Practical Guide through Qualitative Analysis , 2017 .

[12]  Michael Philippsen,et al.  Two Controlled Experiments Assessing the Usefulness of Design Pattern Documentation in Program Maintenance , 2002, IEEE Trans. Software Eng..

[13]  P. Solomon,et al.  Randomized Controlled Trials: Design and Implementation for Community-Based Psychosocial Interventions , 2009 .

[14]  B. J. Ferro Castro,et al.  Pattern-Oriented Software Architecture: A System of Patterns , 2009 .

[15]  John M. Vlissides,et al.  Automatic Code Generation from Design Patterns , 1996, IBM Syst. J..

[16]  Lutz Prechelt,et al.  Design Patterns in Software Maintenance: An Experiment Replication at Freie Universität Berlin , 2011, 2011 Second International Workshop on Replication in Empirical Software Engineering Research.

[17]  Tore Dybå,et al.  The Future of Empirical Methods in Software Engineering Research , 2007, Future of Software Engineering (FOSE '07).

[18]  Neil Salkind Encyclopedia of Measurement and Statistics , 2006 .

[19]  Ralph Johnson,et al.  Design patterns: elements of reuseable object-oriented software , 1994 .

[20]  Natalia Juristo Juzgado,et al.  Report from the 1st international workshop on replication in empirical software engineering research (RESER 2010) , 2010, SOEN.

[21]  Michael Vitale,et al.  The Wisdom of Crowds , 2015, Cell.

[22]  Marco Meijers,et al.  Tool Support for Object-Oriented Patterns , 1997, ECOOP.

[23]  D. A. Kenny,et al.  The moderator-mediator variable distinction in social psychological research: conceptual, strategic, and statistical considerations. , 1986, Journal of personality and social psychology.

[24]  Lerina Aversano,et al.  Relationship between design patterns defects and crosscutting concern scattering degree: an empirical study , 2009, IET Softw..

[25]  Damaris Zurell,et al.  Collinearity: a review of methods to deal with it and a simulation study evaluating their performance , 2013 .

[26]  James Coplien,et al.  Industrial experience with design patterns , 1996, Proceedings of IEEE 18th International Conference on Software Engineering.

[27]  Walter F. Tichy,et al.  A Controlled Experiment in Maintenance Comparing Design Patterns to Simpler Solutions , 2001, IEEE Trans. Software Eng..

[28]  Peter Wendorff Assessment of Design Patterns during Software Reengineering: Lessons Learned from a Large Commercial Project , 2001, CSMR.

[29]  R. Mclean,et al.  A Unified Approach to Mixed Linear Models , 1991 .

[30]  Douglas C. Schmidt,et al.  Pattern-Oriented Software Architecture, Patterns for Concurrent and Networked Objects , 2013 .

[31]  Ioannis Stamelos,et al.  Research state of the art on GoF design patterns: A mapping study , 2013, J. Syst. Softw..

[32]  Claes Wohlin,et al.  Experimentation in Software Engineering , 2012, Springer Berlin Heidelberg.

[33]  Susan A. Murphy,et al.  Monographs on statistics and applied probability , 1990 .

[34]  Walter F. Tichy,et al.  A Controlled Experiment Comparing the Maintainability of Programs Designed with and without Design Patterns—A Replication in a Real Programming Environment , 2004, Empirical Software Engineering.

[35]  Jeffrey C. Carver Towards Reporting Guidelines for Experimental Replications: A Proposal , 2010 .

[36]  Yann-Gaël Guéhéneuc,et al.  Impact of the visitor pattern on program comprehension and maintenance , 2009, 2009 3rd International Symposium on Empirical Software Engineering and Measurement.

[37]  F. Ramsey,et al.  The statistical sleuth : a course in methods of data analysis , 2002 .

[38]  E. Brink,et al.  Constructing grounded theory : A practical guide through qualitative analysis , 2006 .

[39]  Sira Vegas,et al.  Design Patterns in Software Maintenance: An Experiment Replication at UPM - Experiences with the RESER'11 Joint Replication Project , 2011, 2011 Second International Workshop on Replication in Empirical Software Engineering Research.

[40]  Jeffrey C. Carver,et al.  Design Patterns in Software Maintenance: An Experiment Replication at University of Alabama , 2011, 2011 Second International Workshop on Replication in Empirical Software Engineering Research.

[41]  Cheng Zhang,et al.  What Do We Know about the Effectiveness of Software Design Patterns? , 2012, IEEE Transactions on Software Engineering.