An AI-Augmented Framework for Refactoring Enterprise Monolithic Systems

Authors

  • Kishore Subramanya Hebbar

Keywords:

Legacy system modernization, Code refactoring, Monolithic architectures, Microservice migration, AI-assisted software engineering, Enterprise application evolution

Abstract

Many large organizations still depend on legacy monolithic systems that were built over many years and now hold deeply embedded business logic. Moving these systems to cloud-native microservices is widely desired, but the process is slow, risky, and heavily dependent on manual code understanding, which often leads to errors and rework. Current migration approaches either rely on rigid rule-based tools or expect full manual refactoring, leaving a gap in practical support for understanding complex dependencies and identifying safe service boundaries. The goal of this study is to address this gap by providing intelligent, decision-oriented assistance that helps engineers refactor legacy code while preserving existing business behavior. The proposed approach introduces an AI-augmented modular refactoring framework that combines static code analysis, dependency graph modeling, and machine learning-based pattern recognition. Instead of automatically rewriting code, the framework highlights logical decomposition points, detects refactoring candidates, and surfaces architectural risks. A human-in-the-loop workflow allows developers and architects to review, adjust, and validate recommendations before changes are applied, supporting incremental migration rather than disruptive rewrites. Evaluation on enterprise-scale legacy applications shows a reduction of refactoring effort by approximately 25 to 40 percent compared to fully manual approaches. The resulting microservices also exhibit improved modularity and fewer post-migration defects during validation. This framework can be applied to large enterprise modernization initiatives where reliability and domain integrity are critical. By combining human expertise with AI-assisted insight, the work demonstrates a practical and novel way to reduce risk and effort in legacy-to-microservice migration.

Downloads

Download data is not yet available.

References

B. Pérez et al., “Technical debt payment and prevention through the lenses of software architects,” Information and Software Technology, vol. 140, p. 106692, Dec. 2021, doi: 10.1016/j.infsof.2021.106692.

A. Balalaie, A. Heydarnoori, P. Jamshidi, D. A. Tamburri, and T. Lynn, “Microservices migration patterns,” Software: Practice and Experience, vol. 48, no. 11, pp. 2019–2042, Jul. 2018, doi: 10.1002/spe.2608.

J. Fritzsch, J. Bogner, A. Zimmermann, and S. Wagner, “From Monolith to Microservices: A Classification of Refactoring Approaches,” Software Engineering Aspects of Continuous Development and New Paradigms of Software Production and Deployment, pp. 128–141, 2019, doi: 10.1007/978-3-030-06019-0_10.

M. Allamanis, E. T. Barr, P. Devanbu, and C. Sutton, “A Survey of Machine Learning for Big Code and Naturalness,” ACM Computing Surveys, vol. 51, no. 4, pp. 1–37, Jul. 2018, doi: 10.1145/3212695.

S. Li et al., “Understanding and addressing quality attributes of microservices architecture: A Systematic literature review,” Informa- tion and Software Technology, vol. 131, p. 106449, Mar. 2021, doi: 10.1016/j.infsof.2020.106449.

J. Correia and A. Rito Silva, “Identification of monolith functionality refactorings for microservices migration,” Software: Practice and Experience, vol. 52, no. 12, pp. 2664–2683, Aug. 2022, doi: 10.1002/spe.3141.

A. Krause, C. Zirkelbach, W. Hasselbring, S. Lenga, and D. Kroger, “Microservice Decomposition via Static and Dynamic Analysis of the Monolith,” 2020 IEEE International Conference on Software Architecture Companion (ICSA-C), pp. 9–16, Mar. 2020, doi: 10.1109/icsa- c50368.2020.00011.

A. Santos and H. Paula, “Microservice decomposition and evaluation using dependency graph and silhouette coefficient,” 15th Brazilian Symposium on Software Components, Architectures, and Reuse, pp. 51–60, Sep. 2021, doi: 10.1145/3483899.3483908.

M. Brito, J. Cunha, and J. Saraiva, “Identification of microservices from monolithic applications through topic modelling,” Proceedings of the 36th Annual ACM Symposium on Applied Computing, pp. 1409–1418, Mar. 2021, doi: 10.1145/3412841.3442016.

Z. Li, C. Shang, J. Wu, and Y. Li, “Microservice extraction based on knowledge graph from monolithic applications,” Information and Software Technology, vol. 150, p. 106992, Oct. 2022, doi: 10.1016/j.infsof.2022.106992.

A. Bucchiarone, N. Dragoni, S. Dustdar, S. T. Larsen, and M. Mazzara, “From Monolithic to Microservices: An Experience Report from the Banking Domain,” IEEE Software, vol. 35, no. 3, pp. 50–55, May 2018, doi: 10.1109/ms.2018.2141026.

D. Guamán, J. Pérez, J. Diaz, and C. E. Cuesta, “Towards a reference process for software architecture reconstruction,” IET Software, vol. 14, no. 6, pp. 592–606, Dec. 2020, doi: 10.1049/iet-sen.2019.0246.

K. Alkharabsheh, S. Alawadi, V. R. Kebande, Y. Crespo, M. Fernández- Delgado, and J. A. Taboada, “A comparison of machine learning algorithms on design smell detection using balanced and imbalanced dataset: A study of God class,” Information and Software Technology, vol. 143, p. 106736, Mar. 2022, doi: 10.1016/j.infsof.2021.106736.

S. Amershi et al., “Guidelines for Human-AI Interaction,” Proceedings of the 2019 CHI Conference on Human Factors in Computing Systems,

pp. 1–13, May 2019, doi: 10.1145/3290605.3300233.

N. Bjørndal et al., “Benchmarks and performance metrics for assessing the migration to microservice-based architectures”, Journal of Object Technology, Volume 20, no. 2 (2021), pp. 2:1-17, doi:10.5381/jot.2021.20.2.a3.

F. Auer, V. Lenarduzzi, M. Felderer, and D. Taibi, “From monolithic systems to Microservices: An assessment framework,” Information and Software Technology, vol. 137, p. 106600, Sep. 2021, doi: 10.1016/j.infsof.2021.106600.

F. H. Vera-Rivera, C. Gaona, and H. Astudillo, “Defining and measuring microservice granularity—a literature overview,” PeerJ Computer Science, vol. 7, p. e695, Sep. 2021, doi: 10.7717/peerj-cs.695.

M. G. Moreira and B. B. N. De França, “Analysis of Microservice Evolution using Cohesion Metrics,” Proceedings of the 16th Brazilian Symposium on Software Components, Architectures, and Reuse, pp. 40–49, Oct. 2022, doi: 10.1145/3559712.3559716.

S. Hassan, R. Bahsoon, and R. Kazman, “Microservice transition and its granularity problem: A systematic mapping study,” Software: Practice and Experience, vol. 50, no. 9, pp. 1651–1681, Jun. 2020, doi: 10.1002/spe.2869.

M. Wu et al., “On the Way to Microservices: Exploring Problems and Solutions from Online Q&A Community,” 2022 IEEE International Conference on Software Analysis, Evolution and Reengineering (SANER),

pp. 432–443, Mar. 2022, doi: 10.1109/saner53432.2022.00058.

J. Fritzsch, J. Bogner, S. Wagner, and A. Zimmermann, “Microservices Migration in Industry: Intentions, Strategies, and Challenges,” 2019 IEEE International Conference on Software Maintenance and Evolution (ICSME), pp. 481–490, Sep. 2019, doi: 10.1109/icsme.2019.00081.

D. Sas, P. Avgeriou, and U. Uyumaz, “On the evolution and impact of architectural smells an industrial case study,” Empirical Software Engineering, vol. 27, no. 4, Apr. 2022, doi: 10.1007/s10664-022-10132-7.

S. S. de Toledo, A. Martini, and D. I. K. Sjøberg, “Identifying architectural technical debt, principal, and interest in microservices: A multiple- case study,” Journal of Systems and Software, vol. 177, p. 110968, Jul. 2021, doi: 10.1016/j.jss.2021.110968.

I. Pigazzini, F. A. Fontana, V. Lenarduzzi, and D. Taibi, “Towards microservice smells detection,” Proceedings of the 3rd International Conference on Technical Debt, pp. 92–97, Jun. 2020, doi: 10.1145/3387906.3388625.

D. Taibi, V. Lenarduzzi, and C. Pahl, “Microservices Anti-patterns: A Taxonomy,” Microservices, pp. 111–128, Dec. 2019, doi: 10.1007/978-3- 030-31646-4_5.

Downloads

Published

31.07.2023

How to Cite

Kishore Subramanya Hebbar. (2023). An AI-Augmented Framework for Refactoring Enterprise Monolithic Systems. International Journal of Intelligent Systems and Applications in Engineering, 11(8s), 593–604. Retrieved from https://ijisae.org/index.php/IJISAE/article/view/8046