An Interactive and Dynamic Search-Based Approach to Software Refactoring Recommendations

被引:30
|
作者
Alizadeh, Vahid [1 ]
Kessentini, Marouane [2 ]
Mkaouer, Mohamed Wiem [3 ]
Ocinneide, Mel [4 ]
Ouni, Ali [5 ]
Cai, Yuanfang [6 ]
机构
[1] Univ Michigan, Dearborn, MI 48128 USA
[2] Univ Michigan, Dept Comp & Informat Sci, Dearborn, MI 48128 USA
[3] Rochester Inst Technol, B Thomas Golisano Coll Comp & Informat Sci, Software Engn Dept, Rochester, NY 14623 USA
[4] Univ Coll Dublin, Sch Comp Sci, Dublin 4, Ireland
[5] ETS, Montreal, PQ H3C 1K3, Canada
[6] Drexel Univ, Comp Sci, Philadelphia, PA 19104 USA
关键词
Manuals; Tools; Software quality; Maintenance engineering; Optimization; Electronic mail; Search-based software engineering; Refactoring; interactive optimization; software quality; MULTIOBJECTIVE EVOLUTIONARY ALGORITHMS; DEFECTS DETECTION; TOOLS;
D O I
10.1109/TSE.2018.2872711
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
Successful software products evolve through a process of continual change. However, this process may weaken the design of the software and make it unnecessarily complex, leading to significantly reduced productivity and increased fault-proneness. Refactoring improves the software design while preserving overall functionality and behavior, and is an important technique in managing the growing complexity of software systems. Most of the existing work on software refactoring uses either an entirely manual or a fully automated approach. Manual refactoring is time-consuming, error-prone and unsuitable for large-scale, radical refactoring. On the other hand, fully automated refactoring yields a static list of refactorings which, when applied, leads to a new and often hard to comprehend design. Furthermore, it is difficult to merge these refactorings with other changes performed in parallel by developers. In this paper, we propose a refactoring recommendation approach that dynamically adapts and interactively suggests refactorings to developers and takes their feedback into consideration. Our approach uses NSGA-II to find a set of good refactoring solutions that improve software quality while minimizing the deviation from the initial design. These refactoring solutions are then analyzed to extract interesting common features between them such as the frequently occurring refactorings in the best non-dominated solutions. Based on this analysis, the refactorings are ranked and suggested to the developer in an interactive fashion as a sequence of transformations. The developer can approve, modify or reject each of the recommended refactorings, and this feedback is then used to update the proposed rankings of recommended refactorings. After a number of introduced code changes and interactions with the developer, the interactive NSGA-II algorithm is executed again on the new modified system to repair the set of refactoring solutions based on the new changes and the feedback received from the developer. We evaluated our approach on a set of eight open source systems and two industrial projects provided by an industrial partner. Statistical analysis of our experiments shows that our dynamic interactive refactoring approach performed significantly better than four existing search-based refactoring techniques and one fully-automated refactoring tool not based on heuristic search.
引用
下载
收藏
页码:932 / 961
页数:30
相关论文
共 50 条
  • [21] A Search-Based Approach for Software Product Line Design
    Colanzi, Thelma Elita
    Vergilio, Silvia Regina
    Gimenes, Itana M. S.
    Oizumi, Willian Nalepa
    18TH INTERNATIONAL SOFTWARE PRODUCT LINE CONFERENCE (SPLC 2014), VOL 1, 2014, : 237 - 241
  • [22] Search-based Refactoring Using Recorded Code Changes
    Ouni, Ali
    Kessentini, Marouane
    Sahraoui, Houari
    PROCEEDINGS OF THE 17TH EUROPEAN CONFERENCE ON SOFTWARE MAINTENANCE AND REENGINEERING (CSMR 2013), 2013, : 221 - 230
  • [23] Improving Readability of Scratch Programs with Search-based Refactoring
    Adler, Felix
    Fraser, Gordon
    Gruendinger, Eva
    Koerber, Nina
    Labrenz, Simon
    Lerchenberger, Jonas
    Lukasczyk, Stephan
    Schweikl, Sebastian
    IEEE 21ST INTERNATIONAL WORKING CONFERENCE ON SOURCE CODE ANALYSIS AND MANIPULATION (SCAM 2021), 2021, : 120 - 130
  • [24] Search-based software engineering
    Gutjahr, Walter J.
    Harman, Mark
    COMPUTERS & OPERATIONS RESEARCH, 2008, 35 (10) : 3049 - 3051
  • [25] Optimized design refactoring (ODR): a generic framework for automated search-based refactoring to optimize object-oriented software architectures
    Houichime, Tarik
    El Amrani, Younes
    AUTOMATED SOFTWARE ENGINEERING, 2024, 31 (02)
  • [26] Search-based software engineering
    Harman, M
    Jones, BF
    INFORMATION AND SOFTWARE TECHNOLOGY, 2001, 43 (14) : 833 - 839
  • [27] Search-based software maintenance
    O'Keeffe, Mark
    Cinneide, Mel O.
    10TH EUROPEAN CONFERENCE ON SOFTWARE MAINTENANCE AND REENGINEERING, PROCEEDINGS, 2006, : 247 - +
  • [28] Nautilus: An Interactive Plugand-Play Search-Based Software Engineering Framework
    Ferreira, Thiago Nascimento
    Vergilio, Silvia Regina
    Kessentini, Marouane
    IEEE SOFTWARE, 2021, 38 (05) : 73 - 82
  • [29] Search-Based Refactoring Detection from Source Code Revisions
    Hayashi, Shinpei
    Tsuda, Yasuyuki
    Saeki, Motoshi
    IEICE TRANSACTIONS ON INFORMATION AND SYSTEMS, 2010, E93D (04): : 754 - 762
  • [30] Multi-Criteria Code Refactoring Using Search-Based Software Engineering: An Industrial Case Study
    Ouni, Ali
    Kessentini, Marouane
    Sahraoui, Houari
    Inoue, Katsuro
    Deb, Kalyanmoy
    ACM TRANSACTIONS ON SOFTWARE ENGINEERING AND METHODOLOGY, 2016, 25 (03)