How jhansimahanthi/e-commerce works
This is a full-stack e-commerce platform: customers browse and manage carts, check out, pay, and track orders; administrators manage catalog, stock, orders, and payments. Angular routes through a JWT-validating API gateway to independently persisted services, while Kafka supports asynchronous order, payment, inventory, and notification events. The README documents the system-wide communication patterns; sampled source confirms selected controller-to-service and service-to-repository responsibilities. Other detailed service internals and frontend-to-API calls were not sampled, so those links are documented at architecture level.
Main entry points: ApiGatewayApplication.java API gateway · OrderService.java Cart and order lifecycle · InventoryService.java Inventory management · components Angular storefront
Components 22
Customer and Admin UI
- Angular storefront
frontend/src/app/components - Admin dashboard
frontend/src/app/components/admin - Route configuration
frontend/src/app/app.routes.ts
Gateway and Identity
- API gateway
api-gateway/src/main/java/com/ecommerce/gateway/ApiGatewayApplication.java - JWT filter
api-gateway/src/main/java/com/ecommerce/gateway/JwtAuthenticationFilter.java
Commerce Services
- User and auth
user-service/src/main/java/com/ecommerce/user/service/UserService.java - Products and categories
product-service/src/main/java/com/ecommerce/product/service/ProductService.java - Product endpoints
product-service/src/main/java/com/ecommerce/product/controller/ProductController.java - Inventory management
inventory-service/src/main/java/com/ecommerce/inventory/service/InventoryService.java - Cart and order lifecycle
order-service/src/main/java/com/ecommerce/order/service/OrderService.java - Order endpoints
order-service/src/main/java/com/ecommerce/order/controller/OrderController.java - Payment processing
payment-service/src/main/java/com/ecommerce/payment/service/PaymentService.java - Notifications
notification-service/src/main/java/com/ecommerce/notification/service/NotificationService.java
Event Messaging
- Kafka topics
Service Persistence
- User database
- Product database
- Inventory database
- Order database
- Payment database
- Notification database
Other components
- Customer
- Administrator
Connections 28
- Customer → Angular storefront: shops through
- Administrator → Admin dashboard: manages through
- Angular storefront → Route configuration: uses routes
frontend/src/app/app.routes.ts - Admin dashboard → Route configuration: uses routes
frontend/src/app/app.routes.ts - Angular storefront → API gateway: sends REST requests
- Admin dashboard → API gateway: sends REST requests
- API gateway → JWT filter: validates tokens
- JWT filter → User and auth: validates JWT
- API gateway → User and auth: routes requests
- API gateway → Products and categories: routes requests
- API gateway → Inventory management: routes requests
- API gateway → Cart and order lifecycle: routes requests
- API gateway → Payment processing: routes requests
- API gateway → Notifications: routes requests
- Product endpoints → Products and categories: delegates to
product-service/src/main/java/com/ecommerce/product/controller/ProductController.java - Order endpoints → Cart and order lifecycle: delegates to
order-service/src/main/java/com/ecommerce/order/controller/OrderController.java - User and auth → User database: persists users
- Products and categories → Product database: persists catalog
- Inventory management → Inventory database: persists stock
- Cart and order lifecycle → Order database: persists carts and orders
- Payment processing → Payment database: persists payments
- Notifications → Notification database: persists notifications
- Cart and order lifecycle → Kafka topics: publishes order events
- Payment processing → Kafka topics: publishes payment events
- Inventory management → Kafka topics: publishes stock events
- Kafka topics → Inventory management: dispatches order events
- Kafka topics → Cart and order lifecycle: dispatches payment events
- Kafka topics → Notifications: dispatches service events