How gubscruz/platform works
Project Type and Purpose
• This is a polyglot microservices reference platform (built primarily with Spring Boot services in Java and one Python “exchange” service) plus a “docs” site built with MkDocs.
• Its goal is to demonstrate microservices patterns (API Gateway, per‐service database, containerization, CI/CD, Kubernetes) and support hands‐on learning via documentation.
Top‐Level Components
• API clients (e.g., Web UI, Mobile)
• API Gateway service (“gateway‐service”)
• Core microservices:
• auth‐service (handles login/register + JWT issuance)
• account‐service (manages user accounts)
• order‐service (manages orders/items)
• product‐service (manages product catalog)
• exchange‐service (Python script for currency/rate conversion)
• Databases (one PostgreSQL instance per service, migrations via Flyway)
• CI/CD & Deployment:
• Jenkins pipelines (Jenkinsfiles in each service)
• Docker (Dockerfiles) / Docker Compose (compose.yaml) for local dev
• Kubernetes manifests (k8s/*.yaml) for cloud deployment
• Documentation site (MkDocs + GitHub Pages)
Relationships & Data Flows
• Clients → HTTP(s) → API Gateway
• API Gateway:
• Validates/authenticates JWT (via AuthorizationFilter)
• Routes to downstream microservices
• Microservices:
• Each service exposes REST endpoints (Spring Controllers/Resources)
• Services call each other synchronously if required (e.g., order‐service may call product‐service to validate item details)
• exchange‐service can be invoked by order‐service for currency conversion
• Services ↔ Their own PostgreSQL database (isolated schema per service)
• CI/CD:
• Code pushed → Jenkins Pipeline → Docker image build → Push to Registry → Kubernetes rollout
• Documentation:
• MkDocs → serves local preview or deploys to GitHub Pages
Architectural Patterns & Design Principles
• Microservices: fine‐grained, service‐per‐business‐capability
• API Gateway Pattern: single entrypoint, cross‐cutting concerns (CORS, auth)
• Database per Service + Flyway for versioned migrations
• Polyglot approach (Java + Python)
• Containerization (Docker) + Orchestration (Kubernetes)
• CI/CD with Jenkinsfiles in each repo submodule
• Infrastructure as code (k8s YAML, Docker Compose, mkdocs.yml)
Technologies & Frameworks to Annotate
• Spring Boot, Spring MVC, Spring Data, Flyway
• Python 3 (exchange‐service)
• PostgreSQL
• Docker & Docker Compose
• Kubernetes
• Jenkins (CI pipelines)
• MkDocs (documentation)
Step‐by‐Step Construction
3. Behind the Gateway, arrange the five microservices in a row.
6. Surround the service+DB group with a “Kubernetes Cluster” container; annotate that they’re deployed as pods with k8s YAML.
7. Below the cluster, add CI/CD pipeline elements: Jenkins → Docker Registry → Kubernetes.