This repository contains the source code of the book "Microservices Patterns (Chris Richardson)" and the personal study note of Eventuate Tram Framework (The whole solution of transactional messaging for Spring Boot microservices).
This source code was re-organized by the original source code of the book and I make sure each module is runnable.
This is an application called FTGO (Food to Go). Consumers use the FTGO website or mobile application to place food orders at local restaurants. FTGO coordinates a network of couriers who deliver the orders. It's also responsible for pay couriers and restuarants. Restuarants use the FTGO website to edit their menus and manage orders. The application use s various web services, including Stripe for payments, Twilio for messaging, and Amazon Simple Email Service (SES) for email.
- Business Logic Services
- Accounting Service: Handles billing and payments.
- Consumer Service: Manages consumer accounts.
- Delivery Service: Schedule, reschedule, and cancel deliveries.
- Kitchen Service: Manages the preparation of orders.
- Order History Service: Collects order history.
- Order Service: Manages orders.
- Restaurant Service: Maintains information about restaurants.
- API Gateway
- API Gateway: Routes requests to downstream services and API Composition (Aggregation).
- CDC Pipeline
- Eventuate CDC Service: Helps other services publish messages from database to message queues.
- Core
- Spring
- Spring Boot
- Spring Data
- Spring Cloud
- Spring
- Messaging
- Apache Kafka with Apache ZooKeeper
- Eventuate Tram (Transactional messaging framework)
- Database
- API Gateway
- Removed all the proxy classes in the Order Service so that the code organization of 3 sages (the create order sage, the cancel order sage and the revise order sage) is consistent.
- Regenerated the stub for the gRPC server in the Order Service (The gRPC code is incompleted in the original source code and was causing issues when starting the Order Service).
- Finished the routing functionality for the Accounting Service, the Consumer Service, the Delivery Service and the Kitchen Service in the API gateway (Only the routing logic of the Order Service was finished in the original source code).
- Changed the port number of all the services and the API gateway.
- Replaced hardcoded channel names in multiple places. Centralized those channel names in one place.
- Fixed some bugs.
- Added more logging.
- Enhanced API documentation (Swagger UI).