SellingBuddy is a microservices-based e-commerce platform designed to streamline the process of listing products, managing baskets, processing orders, and handling payments. The system is built with scalability and maintainability in mind, utilizing Blazor for the front end and RabbitMQ for inter-service communication via an event-driven architecture.
(Project Architecture Diagram by @TechBuddyTR)
The front-end application is built with Blazor and enables users to:
- Browse and list products.
- Add items to their basket.
- Checkout their basket with shipping and payment details.
- Register and log in to their accounts.
The Blazor Web UI interacts with the API Gateway for backend requests.
The API Gateway, implemented with Ocelot and integrated with Consul, serves as a reverse proxy that routes user requests to the appropriate microservice.
- Manages user registration and login processes.
- Ensures secure authentication and authorization.
- Handles CRUD operations for the shopping basket.
- Stores basket data in Redis for high performance.
- Manages order creation and retrieval.
- Publishes order events to the EventBus for further processing.
- Provides functionalities to:
- Retrieve brands and types.
- Manage product operations such as create, delete, update, and fetch by filters (e.g., brand ID, type ID).
- Upload and retrieve product images.
- Supports paginated item fetching for scalability.
- Sends email notifications to users regarding payment outcomes (success or failure).
- Validates payment information.
- Publishes events for successful or failed payment transactions.
All microservices are decoupled and communicate asynchronously via the EventBus, which uses RabbitMQ.
- The Order Service publishes payment-related events after order creation.
- The Payment Service listens for these events, validates payment details, and publishes a follow-up event.
- The Notification Service listens for the payment validation event and sends an email to the user.
The entire system is fully containerized using Docker, allowing for seamless deployment and scaling.
Unit tests for the EventBus have been implemented to ensure the reliability of inter-service communication.
- Frontend: Blazor
- Backend: .NET (C#), Redis, RabbitMQ
- Containerization: Docker
- Gateway: Ocelot with Consul
- Messaging: RabbitMQ
- Docker
- .NET SDK
- RabbitMQ
- Clone the repository:
git clone https://github.com/MrBuluc/SellingBuddy.git
- Navigate to the project directory and build Docker containers:
docker-compose up --build
- Access the application via the provided URL in your Docker logs.
- Add integration tests for microservices.
- Implement advanced search and filtering options in the Catalog Service.
- Expand notification capabilities (e.g., SMS notifications).
- Add payment gateways for real-world use cases.
Contributions are welcome! Feel free to open issues or submit pull requests to improve the project.
This project is licensed under the MIT License - see the LICENSE file for details.