A full-fledged Shipping & Logistic System built with Spring Boot, Kafka, H2, Redis, and MERN stack integration for frontend. This project demonstrates event-driven architecture, microservices, and real-time logistics management.
| Service | Purpose |
|---|---|
| Order Service | Create, update, and track orders. Publishes order events. |
| Inventory Service | Checks stock, reserves items, and publishes inventory events. |
| Shipment Service | Creates shipments, assigns drivers/vehicles, updates shipment status. Publishes shipment events. |
| Transport Service | Assigns vehicles and drivers (optional separate from Shipment Service). |
| Tracking Service | Updates shipment progress and notifies customers. |
| Notification Service | Sends emails or messages on order/shipment status. |
| API Gateway | Routes requests to respective services. |
| Service Registry (Eureka) | Manages microservice discovery and registration. |
| Zipkin (Distributed Tracing) | Tracks requests across microservices and visualizes end-to-end flow. |
You can view the complete application flow diagram of the Shipping & Logistic microservices system at:
Eraser.io Workspace - Application Flow
- Java 17
- Spring Boot 3 (Spring Web, Spring Data JPA, Spring Kafka, Spring Cloud Config, Spring Cloud Eureka)
- H2 Database (file-based for development)
- Redis (for caching)
- Kafka (for event-driven communication between services)
- Lombok (for boilerplate reduction)
- Kafka Producer/Consumer for Order, Inventory, and Shipment events
- Event wrapper DTO for multiple event types
- Docker (for running microservices)
- Maven (for build and dependency management)
- Git/GitHub (version control)
- Postman (API testing)
- Create new orders with validation
- Update order status (
CREATED,CONFIRMED,FAILED, etc.) - Fetch order by ID
- Publish order events to Kafka
- Check stock availability
- Reserve and release stock
- Publish inventory events to Kafka
- Create shipments for confirmed orders
- Assign drivers and vehicles
- Update shipment status (
CREATED,IN_TRANSIT,OUT_FOR_DELIVERY,DELIVERED) - Publish shipment events for tracking and notifications
- Optional: manage vehicle/driver assignment
- Integrates with Shipment Service for operational management
- Real-time tracking of shipments
- Integrates with Shipment Service and Kafka events
- Email and/or message notifications to customers
- Subscribes to order/inventory/shipment events
- Java 17+
- Maven 3+
- Docker (optional for running multiple services)
- Kafka & Zookeeper (or Docker Compose for Kafka cluster)
- Redis (optional for caching/locking)
- Clone the repository:
git clone https://github.com/amritmaurya1504/logistic-service-app.git
cd logistic-service-app