A fitness web application built with a microservices architecture that analyzes user performance and provides personalized fitness suggestions, safety tips, and detailed insights.
The application helps users track and analyze their activities while improving their performance with AI-driven recommendations.
This project follows a distributed microservices-based approach, making it scalable, modular, and secure.
The system is divided into multiple services, each responsible for a specific domain:
- User Service → Handles user information, profiles, and authentication details.
- Activity Service → Manages and analyzes user activities (running, workouts, etc.).
- AI Service → Provides AI-powered fitness suggestions, safety tips, and performance improvement strategies.
- Eureka Server → Service registry for microservices discovery.
- API Gateway → Central entry point for all requests, managing routing and security.
- Config Service → Centralized configuration management for all services.
- Authentication → Implemented with Keycloak for identity and access management.
- Authorization → Uses OAuth2 with PKCE for secure authentication flows.
- User authentication & profile management.
- Activity tracking and analysis.
- AI-powered fitness suggestions & safety recommendations.
- Microservices-based, ensuring scalability and modularity.
- Centralized configuration & service discovery.
- Secure communication with Keycloak & OAuth2.
- Backend: Java, Spring Boot (Microservices)
- Security: Keycloak, OAuth2 + PKCE( Proof Key for Code Exchange )
- Service Discovery: Eureka
- API Gateway: Spring Cloud Gateway
- Configuration: Spring Cloud Config Server
- AI Processing: Google Gemini API
- Databases: (MySQL/PostgreSQL/MongoDB)
│── user-service/
│── activity-service/
│── ai-service/
│── eureka-server/
│── gateway-service/
│── config-service/
│── README.md
flowchart TD
Client[User / Frontend] -->|HTTP Requests| Gateway[API Gateway]
Gateway -->|Routes| UserService[User Service]
Gateway -->|Routes| ActivityService[Activity Service]
Gateway -->|Routes| AIService[AI Service]
UserService --> DB1[(User Database)]
ActivityService --> DB2[(Activity Database)]
AIService --> DB3[(Gemini API)]
%% Authentication
UserService --> Keycloak[Keycloak Authentication]
%% Config & Discovery
Gateway --> Eureka[Eureka Service Registry]
UserService --> Config[Config Service]
ActivityService --> Config
AIService --> Config
%% Validation flow
ActivityService -->|Validates User| UserService
%% Async Messaging
ActivityService -->|Publishes Activity| RabbitMQ[(RabbitMQ Queue)]
RabbitMQ -->|Consumes| AIService