4.5 Article

What can violations of good practices tell about the relationship between GoF patterns and run-time quality attributes?

期刊

INFORMATION AND SOFTWARE TECHNOLOGY
卷 105, 期 -, 页码 1-16

出版社

ELSEVIER SCIENCE BV
DOI: 10.1016/j.infsof.2018.07.014

关键词

Software architecture; GoF patterns; Design; Quality analysis; Evaluation

资金

  1. Brazilian agency CAPES/Nuffic [034/12]
  2. Brazilian agency CNPq [204607/2013-2]
  3. Brazilian agency INCT-SEC [573963/2008-8, 2008/57870-9]
  4. Dutch agency CAPES/Nuffic [034/12]
  5. Dutch agency CNPq [204607/2013-2]
  6. Dutch agency INCT-SEC [573963/2008-8, 2008/57870-9]

向作者/读者索取更多资源

Context: GoF patterns have been extensively studied with respect to the benefit they provide as problem-solving, communication and quality improvement mechanisms. The latter has been mostly investigated through empirical studies, but some aspects of quality (esp. run-time ones) are still under-investigated. Objective: In this paper, we study if the presence of patterns enforces the conformance to good coding practices. To achieve this goal, we explore the relationship between the presence of GoF design patterns and violations of good practices related to source code correctness, performance and security, via static analysis. Method: Specifically, we exploit static analysis so as to investigate whether the number of violations of good coding practices identified on classes is related to: (a) their participation in pattern occurrences, (b) the pattern category, (c) the pattern in which they participate, and (d) their role within the pattern occurrence. To answer these questions, we performed a case study on approximately 13,000 classes retrieved from five open-source projects. Results: The obtained results suggest that classes not participating in patterns are more probable to violate good coding practices for correctness, performance and security. In a more fine-grained level of analysis, by focusing on specific patterns, we observed that patterns with more complex structure (e.g., Decorator) and pattern roles that are more change-prone (e.g., Subclasses) are more likely to be associated with a higher number of violations (up to 50 times more violations). Conclusion: This finding implies that investing in a well-thought architecture based on best practices, such as patterns, is often accompanied with cleaner code with fewer violations.

作者

我是这篇论文的作者
点击您的名字以认领此论文并将其添加到您的个人资料中。

评论

主要评分

4.5
评分不足

次要评分

新颖性
-
重要性
-
科学严谨性
-
评价这篇论文

推荐

暂无数据
暂无数据