Abstract | Cilj ovog rada je prikazati proces implementacije i primjene arhitekture mikroservisa u domeni aplikacija za web trgovine. Potrebne funkcionalnosti web trgovine izdvajaju se kroz specifikaciju zahtjeva, inicijalno definirajući monolitni blok koji upravlja svim funkcionalnostima aplikacije.
Razdvajanjem i dekompozicijom odgovornosti iz monolita u servise, definira se arhitektura mikroservisa za web trgovinu. Mikroservisi definirani za web trgovinu su servisi za: proizvode, recenzije, narudžbe, plaćanja, asistenciju, i inventar.
Nakon definiranja, implementacija servisa se provodi korištenjem tehnologija Java, Spring Boot i Spring Cloud. Svaki servis se razvija odvojeno kao neovisna jedinica, s odvojenom bazom podataka, ako je potrebna. Dodatno, implementirao je aplikacijsko programsko sučelje (eng. Application Programming Interface, API) u obliku pristupnika koji služi kao glavna ulazna i sigurnosna točka za poslužiteljsku stranu, te servisni registar za upravljanje registracijom servisa. Za implementaciju plaćanja, servis za plaćanje integrira PayPal servis za plaćanje, a za chatbot, asistent servis integrira OpenAI ChatGPT u kombinaciji sa RAG-om (eng. Retrieval-Augmented Generation). Na kraju, Angular okvir se koristi za implementaciju aplikacije na klijentskoj strani, upotpunjući full-stack web aplikacijsko rješenje za platformu web trgovine. |
Abstract (english) | The goal of this paper is to show the process of implementing and applying microservices architecture to the domain of web store applications. The required web shop functionalities are extracted through the requirements specification, initially defining a monolithic block handling all the business logic for the application.
By separating and decomposing the responsibilities from the monolith into the services, a microservices architecture is defined for the web store. The microservices defined for the web store are product, review, order, payment, AI assistant, and inventory services.
Once defined, the services implementation is carried out, through the usage of Java, Spring Boot, and Spring Cloud technologies. Each service is developed separately as an independent unit, with a separate database, if needed. Additionally, an API (Application Programming Interface) gateway is implemented to serve as a main entry and security point for the server-side, and discovery server to handle service registry. For the implementation of payment, the payment service integrates PayPal payment provider, and for the chatbot, the chat service integrates OpenAI ChatGPT paired with RAG (Retrieval-Augmented Generation). To round everything up, Angular framework is used for client-side application implementation, fulfilling a full-stack web application solution for e-commerce web store platform. |