This repository holds the Backend for Connect, a modern application designed to facilitate real-time chat and seamless communication.
- 🔐 Spring Security (MVC) – Stateless JWT-based authentication and role-based authorization for both REST and WebSocket endpoints.
- 📲 STOMP over WebSocket – Real-time bi-directional communication using WebSocket and STOMP protocol.
- 🧾 User Registration & Login APIs – REST endpoints for secure signup, login, and token generation.
- 💬 Chat APIs – Send and receive chat messages through REST or live WebSocket connection.
- 🔄 Kafka Messaging – Asynchronous message streaming for decoupled and scalable communication pipelines.
- ⚡ Redis Buffer – Temporary in-memory storage for messages before being persisted to MongoDB.
- 🧠 MongoDB Storage – Flexible NoSQL data storage for users and message history.
- 🧼 Clean MVC Architecture – Organized into Controllers, Services, Repositories, DTOs, and Config layers.
- 🧪 Functional Programming Style – Uses
Optional
, lambdas, immutable DTOs, and method references for clean and modern Java code. - 📦 Configurable via
application.properties
– Easily switch between dev, test, and prod profiles with Spring Profiles.
Enforces a Monolithic Architecture with modular layering, built for scalability and clean separation of concerns.
- ☕ Java 17
- 🌱 Spring Boot 3
- 🔐 Spring Security (JWT)
- 💬 STOMP WebSocket
- 📨 Apache Kafka
- ⚡ Redis
- 🍃 MongoDB
- 🧪 Lombok + Functional Java
# 1. Clone the repository
git clone https://github.com/AdityaByte/Connect-Backend-SpringBoot.git
cd Connect-Backend-SpringBoot
# 2. Start MongoDB, Redis, and Kafka locally or via Docker
# 3. Configure environment in:
src/main/resources/application.properties
# 4. Build and run the app
./mvnw spring-boot:run