HSHEP: An Optimization-Based Code Smell Refactoring Sequencing Technique

Authors

  • Ritika Maini Department of Computer Science, Sri Guru Granth Sahib World University, India https://orcid.org/0009-0007-9149-426X
  • Navdeep Kaur Department of Computer Science, Sri Guru Granth Sahib World University, India https://orcid.org/0000-0003-4583-1687
  • Amandeep Kaur Department of Computer Engineering, NIT Kurukshetra, India

DOI:

https://doi.org/10.47852/bonviewJCCE42023180

Keywords:

software refactoring, code smell, sequencing, optimization, Spotted Hyena Optimizer (SHO), Emperor Penguin Optimizer

Abstract

The process of refactoring enhances software quality by modifying its design composition while preserving its core framework. However, addressing code smells without appropriate prioritization can be ineffective. Code smells significantly increase maintenance costs and obstruct system evolution. Refactoring sequencing techniques mitigate these issues by improving a system’s internal structure without altering its external behavior. In large-scale systems, the sheer number of code smells can be overwhelming, and not all can be automatically resolved. Hence, prioritizing code smells based on criteria such as risk and importance is essential. This paper introduces a novel hybrid approach utilizing the hybrid spotted hyena and emperor penguin (HSHEP) optimization-based algorithm. This approach aims to optimize the sequence of code smell bugs by incorporating maintainer opinions and requirements, thereby maximizing the resolution of critical code smells. Unlike existing technologies, the HSHEP algorithm combines the strengths of two optimization strategies, offering a unique and innovative solution to refactoring challenges. To validate the effectiveness of the proposed method, it was applied to various large-scale open-source systems, analyzing five different types of code smells. Results demonstrated a significant improvement in maintenance efficiency and system evolution, confirming the superior performance and practical applicability of the HSHEP-based approach.

 

Received: 22 April 2024 | Revised: 13 June 2024 | Accepted: 30 June 2024

 

Conflicts of Interest

The authors declare that they have no conflicts of interest in this work.

 

Data Availability Statement

Data sharing is not applicable to this article as no new data were created or analyzed in this study.

 

Author Contribution Statement

Ritika Maini: Conceptualization, Methodology, Software, Validation, Formal analysis, Investigation, Resources, Data curation, Writing – original draft, Writing – review & editing, Visualization, Funding acquisition. Navdeep Kaur: Supervision. Amandeep Kaur: Project administration.


Metrics

Metrics Loading ...

Downloads

Published

2024-07-10

Issue

Section

Research Articles

How to Cite

Maini, R., Kaur, . N., & Kaur, A. (2024). HSHEP: An Optimization-Based Code Smell Refactoring Sequencing Technique. Journal of Computational and Cognitive Engineering. https://doi.org/10.47852/bonviewJCCE42023180