Welcome to the Microservices Architecture Project, developed as part of the Microservices Architecture course at the University of Quindío. This project demonstrates a robust microservices architecture using a variety of technologies and design patterns for optimal scalability, reliability, and monitoring. All microservices are containerized and orchestrated via Docker Compose, ensuring smooth inter-service communication and easy deployment. 🌐
- Microservices Overview
- Service Architecture
- Deployment and Monitoring
- API Documentation
- Automation and Testing
-
Authentication Service 🔐
- Built with Go and Gorilla Mux.
- Uses JWT for secure authentication.
- Connects to a PostgreSQL database via GORM.
-
BDD Testing Service 🧪
- End-to-end tests written with Gherkin in Cucumber.js.
- Covers all project microservices, generating a detailed HTML report of test results.
-
Logging Service 📜
- Developed with Express.js and TypeScript.
- Utilizes MySQL via Sequelize ORM.
- Listens to logs from a NATS server to track system activity.
-
Health & Monitoring Service 🩺
- Implemented in Python with Flask.
- Uses MySQL and SQLAlchemy for data persistence.
- Monitors the
/healthendpoint of all microservices and sends email alerts to service owners if a service is down.
-
Account Management Service 👥
- Built with Go and Gin framework.
- Integrates with MySQL using GORM.
- Listens for user registration messages from the Authentication Service via NATS to create associated user accounts.
-
Notification Service 📧
- Developed with Python and Flask.
- Sends email notifications via Mailgun.
- Works on demand from the Monitoring Service, with email records saved in MySQL using SQLAlchemy.
-
Gateway Service 🚪
- Centralizes incoming requests and routes them to the appropriate microservices.
- Built with Fastify in JavaScript for efficient request handling.
-
Jenkins Auto-Configuration Package ⚙️
- Automates the execution of BDD tests using Cucumber.js in Jenkins for continuous testing.
Each microservice is deployed within a Docker container. Using Docker Compose, we orchestrate and manage inter-service dependencies, ensuring each microservice communicates seamlessly. The architecture also supports containerized deployment and scaling, ideal for production environments.
- Prometheus Integration: A Prometheus instance is set up to monitor the overall health of the system. However, the core monitoring responsibilities are handled by the Python-based Health & Monitoring Service, which ensures real-time alerts and email notifications.
- Docker Compose: The final
docker-compose.ymlfile orchestrates all containers, handling their deployment and networking, and ensuring unified communication between services.
Detailed OpenAPI documentation for each microservice can be found in the documentation folder. This documentation outlines each API's available endpoints, request parameters, and response structures, allowing for easy interaction and integration with each service.
The project includes a suite of BDD tests that verify the functionality and reliability of all microservices. Jenkins is configured to run these tests automatically, producing HTML reports to display results.
This project showcases a comprehensive microservices architecture with advanced monitoring, logging, testing, and deployment practices. Contributions and feedback are welcome as we continue to enhance and optimize this system!