An Empirical Study on the Occurrences of Code Smells in Open Source and Industrial Projects

被引:2
|
作者
Rahman, Md. Masudur [1 ]
Satter, Abdus [1 ]
Joarder, Md. Mahbubul Alam [1 ]
Sakib, Kazi [1 ]
机构
[1] Univ Dhaka, Inst Informat Technol, Dhaka, Bangladesh
关键词
code smell; open source system; industrial system; empirical study;
D O I
10.1145/3544902.3546634
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
Background: Reusing source code containing code smells can induce significant amount of maintenance time and cost. A list of code smells has been identified in the literature and developers are encouraged to avoid the smells from the very beginning while writing new code or reusing existing code, and it increases time and cost to identify and refactor the code after the development of a system. Again, remembering a long list of smells is difficult specially for the new developers. Besides, two different types of software development environment - open source and industry, might have an effect on the occurrences of code smells. Aims: A study on the occurrences of code smells in open source and industrial systems can provide insights about the most frequently occurring smells in each type of software system. The insights can make developers aware of the most frequent occurring smells, and researchers to focus on the improvement and innovation of automatic refactoring tools or techniques for the smells on priority basis. Method: We have conducted a study on 40 large scale Java systems, where 25 are open source and 15 are industrial systems, for 18 code smells. Results: The results show that 6 smells have not occurred in any system, and 12 smells have occurred 21,182 times in total where 60.66% in the open source systems and 39.34% in the industrial systems. Long Method, Complex Class and Long Parameter List have been seen as frequently occurring code smells. The one tailed t-test with 5% level of significant analysis has shown that there is no difference between the occurrences of 10 code smells in industrial and open source systems, and 2 smells are occurred more frequently in open source systems than industrial systems. Conclusions: Our findings conclude that all smells do not occur at the same frequency and some smells are very frequent. The short list of most frequently occurred smells can help developers to write or reuse source code carefully without inducing the smells from the beginning during software development. Our study also concludes that industry and open source environments do not have significant impact on the occurrences of code smells.
引用
收藏
页码:289 / 294
页数:6
相关论文
共 50 条
  • [1] An Empirical Study of Code Smells in Java']JavaScript Projects
    Saboury, Amir
    Musavi, Pooya
    Khomh, Foutse
    Antoniol, Giulio
    2017 IEEE 24TH INTERNATIONAL CONFERENCE ON SOFTWARE ANALYSIS, EVOLUTION, AND REENGINEERING (SANER), 2017, : 294 - 305
  • [2] An Empirical Study on Code Smells Co-occurrences in Android Applications
    Hamdi, Oumayma
    Ouni, Ali
    AlOmar, Eman Abdullah
    Mkaouer, Mohamed Wiem
    2021 36TH IEEE/ACM INTERNATIONAL CONFERENCE ON AUTOMATED SOFTWARE ENGINEERING WORKSHOPS (ASEW 2021), 2021, : 26 - 33
  • [3] A large-scale empirical study of code smells in JavaScript projects
    David Johannes
    Foutse Khomh
    Giuliano Antoniol
    Software Quality Journal, 2019, 27 : 1271 - 1314
  • [4] Analyzing the Relationship between Community and Design Smells in Open-Source Software Projects: An Empirical Study
    Mumtaz, Haris
    Singh, Paramvir
    Blincoe, Kelly
    PROCEEDINGS OF THE16TH ACM/IEEE INTERNATIONAL SYMPOSIUM ON EMPIRICAL SOFTWARE ENGINEERING AND MEASUREMENT, ESEM 2022, 2022, : 23 - 33
  • [5] A large-scale empirical study of code smells in Java']JavaScript projects
    Johannes, David
    Khomh, Foutse
    Antoniol, Giuliano
    SOFTWARE QUALITY JOURNAL, 2019, 27 (03) : 1271 - 1314
  • [6] Are architectural smells independent from code smells? An empirical study
    Fontana, Francesca Arcelli
    Lenarduzzi, Valentina
    Roveda, Riccardo
    Taibi, Davide
    JOURNAL OF SYSTEMS AND SOFTWARE, 2019, 154 : 139 - 156
  • [7] Object Oriented Metrics Based Empirical Model for Predicting “Code Smells” in Open Source Software
    Kaur S.
    Singh S.
    Journal of The Institution of Engineers (India): Series B, 2023, 104 (01) : 241 - 257
  • [8] The Evolution and Impact of Code Smells: A Case Study of Two Open Source Systems
    Olbrich, Steffen
    Cruzes, Daniela S.
    Basili, Victor
    Zazworka, Nico
    ESEM: 2009 3RD INTERNATIONAL SYMPOSIUM ON EMPIRICAL SOFTWARE ENGINEERING AND MEASUREMENT, 2009, : 391 - +
  • [9] Empirical Study on Code Smells in iOS Applications
    Rahkema, Kristiina
    Pfahl, Dietmar
    2020 IEEE/ACM 7TH INTERNATIONAL CONFERENCE ON MOBILE SOFTWARE ENGINEERING AND SYSTEMS, MOBILESOFT, 2020, : 61 - 65
  • [10] An empirical study of supplementary patches in open source projects
    Park, Jihun
    Kim, Miryung
    Bae, Doo-Hwan
    EMPIRICAL SOFTWARE ENGINEERING, 2017, 22 (01) : 436 - 473