mehdihadeli/go-food-delivery-microservices
🍕 A practical food delivery microservices, built with Golang, Domain-Driven Design, CQRS, Event Sourcing, Vertical Slice Architecture, Event-Driven Architecture, and the latest technologies.
Thành tựu nổi bật
Những danh hiệu mới nhất của dự án
#1 Repository Của Tháng
#1 Repository Của Tháng
#2 Repository Của Tháng
🍕 Go Food Delivery Microservices — mẫu thực chiến microservices bằng Golang
Một dự án thực hành (không hướng doanh nghiệp) triển khai một hệ thống giao đồ ăn microservices bằng Go, kết hợp hàng loạt mô hình kiến trúc và công nghệ hiện đại.
Go Food Delivery Microservices là dự án mở nguồn do Mehdi Hadeli xây dựng, mang tính thực hành cao. Dự án minh họa cách xây dựng một hệ thống microservices hoàn chỉnh bằng Golang, kết hợp nhiều mô hình kiến trúc phần mềm như Microservices, Vertical Slice, CQRS, Domain Driven Design, Event Sourcing, Event Driven Architecture và Dependency Injection. Dự án hỗ trợ cả giao tiếp bất đồng bộ qua RabbitMQ lẫn giao tiếp đồng bộ qua REST và gRPC.
✨ Điểm nổi bật
- Kiến trúc Vertical Slice: tổ chức mã nguồn theo từng slice trục (feature) thay vì theo layer truyền thống.
- Event Driven Architecture: xây dựng lên trên RabbitMQ với một Event Bus tùy chỉnh trong
pkg/messaging/bus/. - Data-Centric Architecture: áp dụng trong Catalogs Read Service dựa trên CRUD.
- Event Sourcing: sử dụng trong các dịch vụ theo dõi như Orders Service.
- CQRS & Mediator Pattern: kết hợp với thư viện Go-MediatR.
- Dependency Injection: dựa trên framework uber-go/fx.
- REST & gRPC: Echo + Swagger cho API, gRPC cho giao tiếp nội bộ.
- Cơ sở dữ liệu đa dạng: Postgres, EventStoreDB (write), MongoDB, Elasticsearch (read).
- Quan sát hệ thống: OpenTelemetry + Jaeger/Zipkin (tracing), Prometheus + Grafana (metrics).
- Kiểm thử toàn diện: Unit Test, Integration Test, End2End Test bằng testcontainers-go.
- Logging & cấu hình: Zap logging, Viper configuration.
- Triển khai: Docker, docker-compose, đang phát triển thêm Helm + Kubernetes.
- Outbox & Inbox Pattern: đảm bảo giao hàng tin nhắn (at-least-once / exactly-once).
💡 Vì sao đáng chú ý
Không chỉ là một dự án demo đơn thuần, Go Food Delivery Microservices cung cấp một bản đồ kiến trúc chi tiết cho cách kết hợp nhiều mô hình thiết kế phần mềm phức tạp trong thực tế. Dự án nằm ở trạng thái đang phát triển, liên tục cập nhật công nghệ mới.
Phù hợp với các nhà phát triển muốn học hỏi hoặc khởi tạo nhanh một dự án microservices backend bằng Go, đặc biệt khi cần áp dụng kiến trúc sạch, CQRS, event sourcing hoặc event-driven communication.
#Microservices #CleanArchitecture #CQRS #EventSourcing #GoLang #TiniX
Similar Projects
Discover other similar projects and AI models.
A Ruby implementation of an Event Store based on Active Record
A Ruby implementation of an Event Store based on Active Record
Full Modular Monolith application with Domain-Driven Design approach.
Framework for Evolutionary Message-Driven Microservices on the JVM
Complete working example of using Domain Driven Design (DDD), Hexagonal Architecture, CQRS, Event Sourcing (ES), Event Driven Architecture (EDA), Behaviour Driven Development (BDD) using TypeScript and NestJS. Like what you see? Don't forget to star! ⭐ ^^^
A reference implementation of an event-sourced system that uses PostgreSQL as an event store built with Spring Boot. Fork the repository and use it as a template for your projects. Or clone the repository and run end-to-end tests to see how everything works together.
Task management system based on .NET 8 with Microservices, DDD, CQRS, Event Sourcing and Testing Concepts
Go DDD example application. Complete project to show how to apply DDD, Clean Architecture, and CQRS by practical refactoring.