Skip to content

Commit 6830a69

Browse files
Merge pull request #54 from nashtech-garage/feature/analyze-microservices
feature analyze and design system architecture for microservice
2 parents d07729e + 853b884 commit 6830a69

File tree

2 files changed

+198
-0
lines changed

2 files changed

+198
-0
lines changed

MICROSERVICES_ARCHITECTURE.md

Lines changed: 198 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,198 @@
1+
# Smart TaskHub - Project Management System
2+
3+
## 📋 Overview
4+
5+
Smart TaskHub is a Trello-like project management platform built with a modern microservices architecture. It provides teams with powerful tools to organize projects, manage tasks, collaborate effectively, and track progress in an intuitive and scalable environment.
6+
7+
## 🏗️ Architecture
8+
9+
![Smart TaskHub Microservices Architecture](backend/smart_taskhub_microservices.png)
10+
11+
The system follows a microservices architecture pattern with the following key components:
12+
13+
- **Frontend**: React Web Application
14+
- **API Gateway**: Kong Gateway for routing and load balancing
15+
- **Authentication**: Keycloak for identity and access management
16+
- **Business Services**: Multiple Play Framework-based microservices
17+
- **Database**: PostgreSQL for data persistence
18+
- **Caching**: Redis for performance optimization
19+
- **External Services**: Mailtrap for email delivery, Cloudinary for file storage
20+
21+
## 🚀 Core Services
22+
23+
### 1. **Identity Service**
24+
- **Technology**: Play Framework (Scala/Java)
25+
- **Function**:
26+
- User registration and authentication
27+
- User profile management
28+
- Integration with Keycloak for SSO
29+
- Role and permission management
30+
31+
### 2. **Project Service**
32+
- **Technology**: Play Framework (Scala/Java)
33+
- **Function**:
34+
- Project creation and management
35+
- Project settings and configuration
36+
- Team member assignment
37+
- Project visibility and access control
38+
39+
### 3. **Workspace Service**
40+
- **Technology**: Play Framework (Scala/Java)
41+
- **Function**:
42+
- Workspace creation and management
43+
- Board organization within workspaces
44+
- Workspace-level permissions
45+
- Team collaboration spaces
46+
47+
### 4. **Task Service**
48+
- **Technology**: Play Framework (Scala/Java)
49+
- **Function**:
50+
- Task creation, updating, and deletion
51+
- Task assignment and status tracking
52+
- Due dates and priority management
53+
- Task dependencies and relationships
54+
- Card movement between lists/columns
55+
56+
### 5. **Comment Service**
57+
- **Technology**: Play Framework (Scala/Java)
58+
- **Function**:
59+
- Task and project commenting system
60+
- Comment threading and replies
61+
- Mention notifications
62+
- Activity feed generation
63+
64+
### 6. **Notification Service**
65+
- **Technology**: Play Framework (Scala/Java)
66+
- **Function**:
67+
- Real-time notifications
68+
- Email notification triggers
69+
- Push notification management
70+
- Notification preferences
71+
72+
### 7. **WebSocket Service**
73+
- **Technology**: Play Framework (Scala/Java)
74+
- **Function**:
75+
- Real-time collaboration features
76+
- Live updates for task changes
77+
- User presence indicators
78+
- Instant messaging capabilities
79+
80+
### 8. **Mail Service**
81+
- **Technology**: Play Framework (Scala/Java)
82+
- **Function**:
83+
- Email template management
84+
- Email sending orchestration
85+
- Integration with Mailtrap service
86+
- Email delivery tracking
87+
88+
### 9. **Media Service**
89+
- **Technology**: Play Framework (Scala/Java)
90+
- **Function**:
91+
- File upload and management
92+
- Image processing and optimization
93+
- Integration with Cloudinary
94+
- Attachment handling for tasks and comments
95+
96+
## 🛠️ Technology Stack
97+
98+
### **Frontend**
99+
- **React**: Modern JavaScript library for building user interfaces
100+
- **Features**: Responsive design, real-time updates, drag-and-drop functionality
101+
102+
### **Backend Services**
103+
- **Play Framework**: High-performance web framework for Java and Scala
104+
- **Benefits**: Reactive programming, built-in testing, RESTful APIs
105+
106+
### **API Gateway**
107+
- **Kong**: Cloud-native API gateway
108+
- **Features**: Load balancing, rate limiting, authentication, monitoring
109+
110+
### **Authentication & Authorization**
111+
- **Keycloak**: Open-source identity and access management
112+
- **Features**: SSO, OAuth 2.0, RBAC, user federation
113+
114+
### **Database**
115+
- **PostgreSQL**: Advanced open-source relational database
116+
- **Features**: ACID compliance, JSON support, full-text search
117+
118+
### **Caching**
119+
- **Redis**: In-memory data structure store
120+
- **Use Cases**: Session storage, API response caching, real-time data
121+
122+
### **External Services**
123+
- **Mailtrap**: Email testing and delivery service
124+
- **Cloudinary**: Cloud-based image and video management platform
125+
126+
## 🔄 System Flow
127+
128+
1. **User Access**: Users access the React frontend application
129+
2. **API Gateway**: All requests are routed through Kong Gateway
130+
3. **Authentication**: Keycloak handles user authentication and authorization
131+
4. **Service Communication**: Microservices communicate via REST APIs
132+
5. **Data Persistence**: PostgreSQL stores all application data
133+
6. **Caching**: Redis improves performance with intelligent caching
134+
7. **Real-time Updates**: WebSocket service enables live collaboration
135+
8. **External Integration**: Mailtrap and Cloudinary handle specialized functions
136+
137+
## 📁 Project Structure
138+
139+
```
140+
smart-taskhub/
141+
├── frontend/ # React Web Application
142+
├── api-gateway/ # Kong Gateway Configuration
143+
├── services/
144+
│ ├── identity-service/ # User Management
145+
│ ├── project-service/ # Project Management
146+
│ ├── workspace-service/ # Workspace Management
147+
│ ├── task-service/ # Task Management
148+
│ ├── comment-service/ # Comment System
149+
│ ├── notification-service/# Notification System
150+
│ ├── websocket-service/ # Real-time Communication
151+
│ ├── mail-service/ # Email Management
152+
│ └── media-service/ # File Management
153+
├── infrastructure/
154+
│ ├── database/ # PostgreSQL Configuration
155+
│ ├── cache/ # Redis Configuration
156+
│ └── keycloak/ # Authentication Configuration
157+
└── docs/ # Documentation
158+
```
159+
160+
## 🚦 Getting Started
161+
162+
### Prerequisites
163+
- Docker and Docker Compose
164+
- Node.js (for frontend development)
165+
- Java 11+ (for backend services)
166+
- PostgreSQL
167+
- Redis
168+
169+
### Quick Start
170+
1. Clone the repository
171+
2. Set up environment variables
172+
3. Start infrastructure services (PostgreSQL, Redis, Keycloak)
173+
4. Deploy microservices
174+
5. Launch the frontend application
175+
6. Configure Kong Gateway routes
176+
177+
## 🔧 Configuration
178+
179+
Each service requires specific configuration for:
180+
- Database connections
181+
- Redis cache settings
182+
- Keycloak authentication
183+
- External service API keys (Mailtrap, Cloudinary)
184+
- Service discovery and communication
185+
186+
## 📊 Key Features
187+
188+
- **Kanban Boards**: Visual task management with drag-and-drop
189+
- **Team Collaboration**: Real-time updates and commenting
190+
- **File Attachments**: Media upload and management
191+
- **Email Notifications**: Automated email alerts
192+
- **User Management**: Role-based access control
193+
- **Scalable Architecture**: Microservices for independent scaling
194+
- **Real-time Sync**: Live updates across all connected clients
195+
196+
## 🤝 Contributing
197+
198+
This project follows microservices best practices and welcomes contributions to individual services or the overall architecture.
299 KB
Loading

0 commit comments

Comments
 (0)