Architectural Modernization of Legacy PHP Systems : Performance, Maintainability, and the Role of AI-assisted Development
Glushenkova, Mariia (2025)
Glushenkova, Mariia
2025
All rights reserved. This publication is copyrighted. You may download, display and print it for Your own personal use. Commercial use is prohibited.
Julkaisun pysyvä osoite on
https://urn.fi/URN:NBN:fi:amk-2025120432550
https://urn.fi/URN:NBN:fi:amk-2025120432550
Tiivistelmä
Legacy applications built with a mix of HTML, PHP, and JavaScript are still widely
used, but their tightly coupled structure makes them difficult to maintain, extend,
and secure. This thesis explores how such systems can be effectively
modernized by redesigning a representative part of the Digitized Commitment
Management (DCM) tool into modular React and Node.js architecture. The goal
was to improve maintainability and performance while introducing a clearer and
more consistent application structure.
The modernization effort included rebuilding the frontend as a component-based
React application, introducing a dedicated Node.js API layer with parameterized
SQL queries, and replacing ad-hoc PHP session handling with a Microsoft Entra
ID authentication flow. These changes separated concerns that had previously
been mixed, resulting in a cleaner, more reusable, and easier-to-maintain
codebase. AI tools were used in a supportive role to speed up repetitive tasks
such as scaffolding and pattern extraction. All generated output was manually
reviewed to ensure correctness and security, making AI an accelerator rather
than a decision-maker. The modernized solution was evaluated across
performance, maintainability, security, and developer productivity.
The results show clear improvements: significantly faster page rendering,
reduced code duplication, stronger security through a centralized backend, and
significantly more maintainable architecture. The results show that architectural
redesign is the primary driver of modernization success. When combined with
disciplined, review-driven AI assistance, modernization becomes both technically
feasible and organizationally sustainable. The study demonstrates how legacy
PHP systems can evolve into modular, maintainable, and secure platforms
aligned with contemporary enterprise standards.
used, but their tightly coupled structure makes them difficult to maintain, extend,
and secure. This thesis explores how such systems can be effectively
modernized by redesigning a representative part of the Digitized Commitment
Management (DCM) tool into modular React and Node.js architecture. The goal
was to improve maintainability and performance while introducing a clearer and
more consistent application structure.
The modernization effort included rebuilding the frontend as a component-based
React application, introducing a dedicated Node.js API layer with parameterized
SQL queries, and replacing ad-hoc PHP session handling with a Microsoft Entra
ID authentication flow. These changes separated concerns that had previously
been mixed, resulting in a cleaner, more reusable, and easier-to-maintain
codebase. AI tools were used in a supportive role to speed up repetitive tasks
such as scaffolding and pattern extraction. All generated output was manually
reviewed to ensure correctness and security, making AI an accelerator rather
than a decision-maker. The modernized solution was evaluated across
performance, maintainability, security, and developer productivity.
The results show clear improvements: significantly faster page rendering,
reduced code duplication, stronger security through a centralized backend, and
significantly more maintainable architecture. The results show that architectural
redesign is the primary driver of modernization success. When combined with
disciplined, review-driven AI assistance, modernization becomes both technically
feasible and organizationally sustainable. The study demonstrates how legacy
PHP systems can evolve into modular, maintainable, and secure platforms
aligned with contemporary enterprise standards.
