This is a template for a pizza bakery webshop hackathon project. The project follows a microservices architecture with Domain-Driven Design principles.
The solution consists of the following components:
- Frontend: Blazor Server application for the web interface
- Gateway: API Gateway for routing requests to microservices
- Webhooks: Worker service for handling webhook events
- Menu: Complete microservice for managing the pizza menu
- Orders: Service for handling pizza orders
- Production: Service for managing pizza production
- Delivery: Service for handling pizza delivery
The project follows these architectural patterns:
- Onion Architecture
- Microservices
- Gateway Pattern
- Domain-Driven Design (DDD)
Each microservice follows this structure:
[ServiceName].Api: ASP.NET API (read-only)[ServiceName].ApiClient: Auto-generated Swagger client[ServiceName].Worker: ASP.NET Worker (write-only)[ServiceName].Messages: Library for message contracts[ServiceName].Core: Library for core business logic[ServiceName].Infrastructure: Library for infrastructure concerns[ServiceName].Domain: Library for domain models[ServiceName].Migrations: Library for database migrations
The project uses:
- PostgreSQL for data storage
- RabbitMQ for message brokering
- MassTransit for message handling
- Entity Framework Core for data access
- Clone the repository
- Install the required tools:
- .NET 9.0 SDK
- Docker Desktop (for PostgreSQL and RabbitMQ)
- Run the infrastructure:
docker-compose up -d
- Build and run the solution:
dotnet build dotnet run
- Follow DDD principles when designing domain models
- Use CQRS pattern for separating read and write operations
- Implement proper error handling and logging
- Write unit tests for core business logic
- Document API endpoints using Swagger
- Create a feature branch for your changes
- Implement your changes following the architecture guidelines
- Submit a pull request for review
This project is licensed under the MIT License.