How manu05x/microsevicespringboot works
Main Components
• Microservices:
• Food Catalogue Microservice (FoodCatalogueMicroservice): Contains controllers, DTOs, entities, mappers, services, and repositories.
• Order Microservice (OrderMS): Implements order-related logic with controllers, DTOs for orders and food items, entities, repositories, and service layers.
• User Information Microservice (UserInformation): Manages user data with its dedicated controller, DTOs, entities, mappers, and service.
• Restaurant Listing / Restaurant Microservice (restaurantListing): Handles restaurant data, structured similarly to other services.
• Service Discovery:
• Eureka: Acts as the service registry, enabling dynamic discovery and communication among the microservices.
• Frontend:
• Food Delivery Application (food-delivery-app): This Angular-based project serves as the client/user interface.
• Infrastructure/Deployment:
• Deployment scripts and configurations (deployment-folder and Notes) for AWS, Docker, and Kubernetes, which guide the containerization and orchestration of these services.
Relationships and Interactions Between Components
• The Angular “food-delivery-app” front end interacts with the backend microservices through REST API calls. It might use an API gateway pattern if one exists (or connect directly by consulting the Eureka service registry).
• All microservices are built using Spring Boot. They expose RESTful endpoints (e.g., FoodCatalogueController, OrderController, UserController, RestaurantController) that the front-end consumes.
• Eureka provides service registration and discovery. Each microservice registers itself with Eureka, and the client or any inter-service communication may use Eureka to locate services.
• The services internally use a layered design pattern (controller → service → repository) for business logic separation and database interaction (even if actual database configuration isn’t visible in the file structure, the presence of repository and entity directories indicate persistence layers).
• Given the separate configuration files (application-{env}.yml and properties files), each microservice is environment-aware and can be configured differently depending on the deployment environment.
Architectural Patterns and Design Principles
• Microservices Architecture: Each service is independently deployable; they follow a common pattern with clear separation of concerns.
• Layered (or n-tier) design: Each service contains controllers, services, repositories, and DTO layers that encapsulate presentation, business logic, data access, and data abstraction respectively.
• Containerization: Dockerfiles in each microservice and the presence of Kubernetes manifests show that these services are packaged as containers and managed through orchestration tools.
• Service Discovery: The Eureka server is key to allowing dynamic client and inter-service communication.
Elements
• Components:
• Angular Frontend (“food-delivery-app”)
• Food Catalogue Microservice (with its internal layers: Controller, Service, Repository, etc.)
• Order Microservice (similarly broken down)
• User Information Microservice
• Restaurant Listing Microservice
• Eureka Server (Service Discovery)
• Deployment/Infrastructure Layer (Docker, Kubernetes cluster, AWS cloud)
• Optionally, indicate intra-service communication if one microservice might directly call another (e.g., OrderMS could call FoodCatalogue).
• Visual Distinctions:
• Differentiate between frontend, backend, and infrastructural elements.
• Additional Notations:
• Annotations highlighting technologies (Spring Boot, Angular, Docker, Kubernetes, AWS) and configuration details from the deployment manifests.