Context: The term technical debt (TD) describes the aggregation of sub-optimal solutions that serve to impede the evolution and maintenance of a system. Some claim that the broken windows theory (BWT), a concept borrowed from criminology, also applies to software development projects. The theory states that the presence of indications of previous crime (such as a broken window) will increase the likelihood of further criminal activity; TD could be considered the broken windows of software systems. Objective: To empirically investigate the causal relationship between the TD density of a system and the propensity of developers to introduce new TD during the extension of that system. Method: The study used a mixed-methods research strategy consisting of a controlled experiment with an accompanying survey and follow-up interviews. The experiment had a total of 29 developers of varying experience levels completing system extension tasks in already existing systems with high or low TD density. Results: The analysis revealed significant effects of TD level on the subjects' tendency to re-implement (rather than reuse) functionality, choose non-descriptive variable names, and introduce other code smells identified by the software tool SonarQube, all with at least 95% credible intervals. Conclusions: Three separate significant results along with a validating qualitative result combine to form substantial evidence of the BWT's existence in software engineering contexts. This study finds that existing TD can have a major impact on developers propensity to introduce new TD of various types during development.
翻译:背景:术语"技术债务"(TD)描述了阻碍系统演进与维护的次优解决方案的累积。有观点认为,借用于犯罪学的破窗理论(BWT)同样适用于软件开发项目。该理论指出,先前犯罪迹象(如破窗)的存在会增加进一步犯罪活动的可能性;技术债务可被视为软件系统中的"破窗"。目标:通过实证研究系统技术债务密度与开发者在系统扩展过程中引入新技术债务倾向之间的因果关系。方法:本研究采用混合方法研究策略,包括受控实验、配套问卷调查及后续访谈。实验共招募29名不同经验水平的开发者,分别在技术债务密度高/低的既有系统中完成系统扩展任务。结果:分析表明,技术债务水平对受试者倾向产生显著影响,具体表现为:重新实现(而非重用)功能、使用非描述性变量名、以及引入SonarQube软件工具识别的其他代码异味——所有结果均具有至少95%的置信区间。结论:三项独立的显著结果与一项验证性定性结果相结合,为破窗理论在软件工程语境中的存在提供了有力证据。本研究发现,既有技术债务会显著影响开发者在开发过程中引入各类新技术债务的倾向。