A clone version of Slack application with minimal functionalities, deployed on Kubernetes using Microservices architecture.
- Native login/signup authentication using JWT
- API requests authentication to downstream services through Kong Gateway
- OAuth 2.0 authenticate, with providers such as Google, Github, LinkedIn
- The backend HTTP service communicating with AWS Gateway WebSocket API
- Receiving $connect, $default and $disconnect events from the Web UI, then write to key-value store Redis for other realtime workloads.
- Consuming internal events, via RabbitMQ work queues, produced by other services and broadcast to interested client apps (identify by websocket connection id).
- Leveraging Redis keyspace notifications to implement realtime presence mechanism, in order to broadcast a particular user's status (online/offline) to other interested participants
- Fully asynchronous implementation with FastAPI, FastStream, Redis Asyncio and SQLAlchemy Asyncio
- Managing channels, members and messages generated from Web UI
- Publishing various events (
message.sent
,member.joined
,member.leave
,...) to RabbitMQ - Developed using TDD method with testing libraries: Pytest, Factory Boy
- FastAPI implementation as an intermediate layer before the inference with LLM models:
- Serving model via HuggingFace TGI with the following models: Llama-3, Mistral-7B, Phi-2
- Serving messages via LangServe and chat history with LangChain Memory
- A read-only service for querying replicated data from PostgreSQL slave-database with SQLAlchemy
- Data replication is implemented using Debezium Kafka Connect
- Modern front-end NextJS application with modern libraries:
- TypeScript, Tailwind, Redux, React Hook Form, React Use WebSocket, React Virtualized