Develop the Python FastAPI backend services for user registration, secure login (JWT-based), user profile management (view and edit), and user search functionality. This includes implementing secure password hashing (bcrypt), API rate limiting on authentication and registration endpoints, and defining the initial PostgreSQL database schema for users.
### 1.1 Database Schema for Users
- [x] Define and implement the PostgreSQL schema for users.
### 1.2 User Entity and Repository
- [x] Create the User entity and Spring Data JPA repository.
### 1.3 Authentication Service (Registration & Login)
- [x] Implement user registration with password hashing (bcrypt) and JWT-based login.
### 1.4 User Profile Service
- [x] Define UserProfile DTO for request and response.
- [x] Implement service method to retrieve user profile by ID.
- [x] Implement service method to update user profile.
- [x] Create REST controller endpoints for user profile management.
### 1.5 User Search Service
- [x] 1.5.1 Create UserSearchDTO for search results.
Integrate the existing Angular Clarity frontend components for user authentication and profile management with the new FastAPI backend. This involves adapting the login, registration, and profile UI to consume the new backend APIs, implementing secure JWT handling (e.g., HttpOnly cookies, token refresh), developing new UI for user search, and displaying user online/offline presence. Also, implement a strict Content Security Policy (CSP) for the frontend.
Implement the core one-to-one real-time messaging functionality. This includes:
- **Backend:** Developing FastAPI/Starlette WebSocket services for real-time message delivery, implementing message persistence in PostgreSQL, utilizing Redis for Pub/Sub to scale WebSocket services, and using Redis Streams/Lists for guaranteed message delivery to offline users.
- **Frontend:** Developing Angular UI components for displaying a list of active conversations, an interactive chat window for sending and receiving messages in real-time, and efficiently loading and displaying historical messages.
## Task 4: Implement Full-Stack Group Chat Capabilities [FULL-STACK]
Extend the messaging application to support group conversations. This task involves:
- **Backend:** Developing APIs and WebSocket logic for creating new group chats, managing group members (add/remove), and handling message sending/receiving within groups.
- **Frontend:** Developing UI for creating and managing group chats, displaying group conversation lists, and an enhanced chat interface for group messaging.
## Task 5: Develop Full-Stack Enhanced Communication Features [FULL-STACK]
Introduce advanced communication features to enrich the user experience. This includes:
- **Backend:** Developing services for real-time new message notifications, user status notifications, and integrating with object storage for media sharing (upload/storage).
- **Frontend:** Implementing UI for displaying in-app notifications, visual indicators for user status, and functionality for uploading and displaying various media types within chat conversations.