A Controlled Experiment in Maintenance Comparing Design Patterns to Simpler Solutions
-
Tagung:
Zeitschriftenartikel
-
Autoren:
Lutz Prechelt
Barbara Unger
Walter F. Tichy
Peter Brüssler
Lawrence G. Votta -
Summary
Software design patterns package proven solutions to recurring design problems in a form that simplifies reuse. We are seeking empirical evidence whether using design patterns is beneficial. In particular, one may prefer using a design pattern even if the actual design problem is simpler than that solved by the pattern, i.e., if not all of the functionality offered by the pattern is actually required. Our experiment investigates software maintenance scenarios that employ various design patterns and compares designs with patterns to simpler alternatives. The subjects were professional software engineers. In most of our nine maintenance tasks, we found positive effects from using a design pattern: Either its inherent additional flexibility was achieved without requiring more maintenance time or maintenance time was reduced compared to the simpler alternative. In a few cases, we found negative effects: The alternative solution was less error-prone or required less maintenance time. Although most of these effects were expected, a few were surprising: A negative effect occurs although a certain application of the Observer pattern appears to be well justified and a positive effect occurs despite superfluous flexibility (and, hence, complexity) introduced by a certain application of the Decorator pattern. Overall, we conclude that, unless there is a clear reason to prefer the simpler solution, it is probably wise to choose the flexibility provided by the design pattern because unexpected new requirements often appear. We identify several questions for future empirical research.
-
Jahr:
2001
- Links:
Titel Vorname Nachname |
---|
Dr. Barbara Unger |
Prof. em. Dr. Walter F. Tichy |
Prof. Dr. Lutz Prechelt |
Bibtex
@article{,
author={Lutz Prechelt, Barbara Unger, Walter F. Tichy, Peter Br{\"o}ssler, Lawrence G. Votta},
title={A Controlled Experiment in Maintenance Comparing Design Patterns to Simpler Solutions},
year=2001,
month=Dec,
volume={27},
url={https://ps.ipd.kit.edu/downloads/za_2001_controlled_experiment_maintenance_comparing_design_pattern.pdf},
abstract={Software design patterns package proven solutions to recurring design problems in a form that simplifies reuse. We are seeking empirical evidence whether using design patterns is beneficial. In particular, one may prefer using a design pattern even if the actual design problem is simpler than that solved by the pattern, i.e., if not all of the functionality offered by the pattern is actually required. Our experiment investigates software maintenance scenarios that employ various design patterns and compares designs with patterns to simpler alternatives. The subjects were professional software engineers. In most of our nine maintenance tasks, we found positive effects from using a design pattern: Either its inherent additional flexibility was achieved without requiring more maintenance time or maintenance time was reduced compared to the simpler alternative. In a few cases, we found negative effects: The alternative solution was less error-prone or required less maintenance time. Although most of these effects were expected, a few were surprising: A negative effect occurs although a certain application of the Observer pattern appears to be well justified and a positive effect occurs despite superfluous flexibility (and, hence, complexity) introduced by a certain application of the Decorator pattern. Overall, we conclude that, unless there is a clear reason to prefer the simpler solution, it is probably wise to choose the flexibility provided by the design pattern because unexpected new requirements often appear. We identify several questions for future empirical research.},
number={12},
pages={1134-1144},
journal={IEEE Transactions on Software Engineering},
}