Determination of optimum refactoring sequence for maximizing the maintainability of object-oriented systems using machine learning algorithms

被引:0
作者
Tarwani, Sandhya [1 ]
Chug, Anuradha [2 ]
机构
[1] Vivekananda Inst Profess Studies, Sch Engn & Technol, Outer Ring Rd,AU Block,Tech Campus, New Delhi 110034, India
[2] Guru Gobind Singh Indraprastha Univ, Univ Sch Informat Commun & Technol, sec 16, New Delhi, India
关键词
Refactoring; Bad smells; Optimum sequence; Maintainability; Decision tree forest; Linear regression; SOFTWARE; MODEL;
D O I
10.1007/s13198-024-02639-7
中图分类号
T [工业技术];
学科分类号
08 ;
摘要
Refactoring is a technique for changing internal attributes without affecting external ones in an optimized manner. Bad smells in the source code can cause various issues, increasing the need for refactoring. In this study, prioritization of classes is initially performed using a newly proposed metric called the Quality Decline Factor (QDF), which considers an appropriate ratio of software metrics along with eleven detected types of bad smells. Next, these bad smells are addressed by applying refactoring techniques, and changes in the metrics are observed. Subsequently, machine learning algorithms are used to assign weights to each metric, leading to the proposal of another new metric, the Total Refactoring Index (TRI). TRI combines the assigned weights and the effects of metric changes to determine the optimal refactoring sequence. The results indicate that the Decision Tree Forest algorithm is the most suitable for determining the refactoring sequence. After applying this technique, a 94.9% reduction in effort was observed. This study would benefit software maintainers by providing predefined sequences, allowing them to focus only on the code sections with the highest concentration of bad smells, thus completing projects within real-time constraints.
引用
收藏
页码:651 / 666
页数:16
相关论文
共 52 条
[1]   Refactoring Inspection Support for Manual Refactoring Edits [J].
Alves, Everton L. G. ;
Song, Myoungkyu ;
Massoni, Tiago ;
Machado, Patricia D. L. ;
Kim, Miryung .
IEEE TRANSACTIONS ON SOFTWARE ENGINEERING, 2018, 44 (04) :365-383
[2]   Machine Learning from Theory to Algorithms: An Overview [J].
Alzubi, Jafar ;
Nayyar, Anand ;
Kumar, Akshi .
SECOND NATIONAL CONFERENCE ON COMPUTATIONAL INTELLIGENCE (NCCI 2018), 2018, 1142
[3]   Performance-driven software model refactoring [J].
Arcelli, Davide ;
Cortellessa, Vittorio ;
Di Pompeo, Daniele .
INFORMATION AND SOFTWARE TECHNOLOGY, 2018, 95 :366-397
[4]   An experimental investigation on the innate relationship between quality and refactoring [J].
Bavota, Gabriele ;
De Lucia, Andrea ;
Di Penta, Massimiliano ;
Oliveto, Rocco ;
Palomba, Fabio .
JOURNAL OF SYSTEMS AND SOFTWARE, 2015, 107 :1-14
[5]   Random forests [J].
Breiman, L .
MACHINE LEARNING, 2001, 45 (01) :5-32
[6]   On the Impact of Refactoring Operations on Code Quality Metrics [J].
Chaparro, Oscar ;
Bavota, Gabriele ;
Marcus, Andrian ;
Di Penta, Massimiliano .
2014 IEEE INTERNATIONAL CONFERENCE ON SOFTWARE MAINTENANCE AND EVOLUTION (ICSME), 2014, :456-460
[7]   How does refactoring affect internal quality attributes? A multi-project study [J].
Chavez, Alexander ;
Ferreira, Isabella ;
Fernandes, Eduardo ;
Cedrim, Diego ;
Garcia, Alessandro .
XXXI BRAZILIAN SYMPOSIUM ON SOFTWARE ENGINEERING (SBES 2017), 2017, :74-83
[8]   A METRICS SUITE FOR OBJECT-ORIENTED DESIGN [J].
CHIDAMBER, SR ;
KEMERER, CF .
IEEE TRANSACTIONS ON SOFTWARE ENGINEERING, 1994, 20 (06) :476-493
[9]   A New Model for Predicting Component-Based Software Reliability Using Soft Computing [J].
Diwaker, Chander ;
Tomar, Pradeep ;
Solanki, Arun ;
Nayyar, Anand ;
Jhanjhi, N. Z. ;
Abdullah, Azween ;
Supramaniam, Mahadevan .
IEEE ACCESS, 2019, 7 :147191-147203
[10]  
Dubey SK., 2011, ACM SIGSOFT SOFTW EN, DOI [DOI 10.1145/2020976.2020983, 10.1145/2020976.2020983]