Enhancing CQRS Implementation Through AI-Driven Refactoring: Query and Command Classification
摘要
A strategy driven by AI is suggested for refactoring legacy systems. This involves categorizing system functions into commands and queries for implementing CQRS. A key-value AI transformer is utilized to examine the source code, offering insights into the architectural structure and assisting in optimizing system functionalities. This approach has produced positive results, effectively segregating legacy classes into commands and queries. Future efforts will concentrate on enhancing the AI model and investigating its integration with other software development practices, with the goal of improving the refactoring of legacy systems, the initial deployment of this strategy, the AI-driven program was able to successfully dissect a pre-existing, complex legacy class by identifying distinct commands and queries within the class, primarily based on method names. This approach, serving as a critical classification stage in the AI-driven refactoring strategy, provided a detailed understanding of each method’s purpose, discerning whether a method was designed for data retrieval or data updating.