A microservices-based personal finance tracking application built with Java 21 and Spring Boot 3.
The system is composed of three independently deployable services behind a single API Gateway:
Client → API Gateway (:8080)
├── /accounts/** → Accounts Service (:8081)
└── /transactions/** → Transactions Service (:8082)
| Service | Port | Responsibility |
|---|---|---|
api-gateway |
8080 | Request routing, single entry point |
accounts-service |
8081 | User account management |
transactions-service |
8082 | Financial transaction tracking |
- Java 21
- Spring Boot 3.3 — web, validation, actuator
- Spring Cloud Gateway — API gateway and routing
- SpringDoc OpenAPI — Swagger UI per service
- Gradle (multi-module build)
- JUnit 5 — testing
- JDK 21+
- Gradle (or use the included
gradlewwrapper)
./gradlew buildStart each service in a separate terminal:
# API Gateway
./gradlew :api-gateway:bootRun
# Accounts Service
./gradlew :accounts-service:bootRun
# Transactions Service
./gradlew :transactions-service:bootRun| Gateway Path | Forwarded To |
|---|---|
/accounts/** |
http://localhost:8081/... |
/api/v1/accounts/** |
http://localhost:8081/... |
/transactions/** |
http://localhost:8082/... |
/api/v1/transactions/** |
http://localhost:8082/... |
Each service exposes health and info endpoints:
- Gateway:
http://localhost:8080/actuator/health - Accounts:
http://localhost:8081/actuator/health - Transactions:
http://localhost:8082/actuator/health
UserFinancialTracker/
├── api-gateway/ # Spring Cloud Gateway
├── accounts-service/ # Account management service
├── transactions-service/ # Transaction tracking service
├── build.gradle # Root build config (shared deps, Java 21 toolchain)
└── settings.gradle # Module declarations
./gradlew test