How zorlight/letslearn works
1. A robust Java-based backend built with Spring Boot (using Maven for dependency management). This backend houses controllers, services, repositories, and configurations (including security with JWT, password encoding, and global exception handling) to support the API endpoints for managing courses, assignments, quizzes, courses’ files, meetings, and messaging.
2. A rich React/Next.js “ui” application that is highly modular, with dedicated sections for dashboard views, course creation and participation, meeting interfaces, quiz attempts, and various components (such as charts, tables, modals, and skeleton states) that give it a modern look and feel.
Additional specialized servers
• The “livekit-server” (developed in Go) which appears to handle real-time video conferencing and chat via LiveKit integration.
• The “tldraw-server” which likely acts as a real-time collaborative whiteboard/drawing component for in-meeting interactions.
4. Several Dockerfiles (in the backend, livekit-server, and tldraw-server directories) along with a docker-compose.yaml at the project root, suggesting that these components are containerized and orchestrated together.
a. Main Components to Include:
• Frontend UI: A Next.js application managing the user interface, routing, and state (with Redux, hooks, etc.).
• Backend API Server: The Spring Boot application that handles REST endpoints, authentication, business logic, data processing, and WebSocket connections.
• Video Conferencing Service: The Livekit server (in Go) responsible for real-time communication (video, audio, chat) during meetings.
• Whiteboard Service: The tldraw server currently used for collaborative drawing/whiteboarding sessions.
• Data Persistence Layer: Though not explicitly named in the file tree, include a relational database (or similar storage) which is interfaced via the repository layer in the backend.
• Cloud/Third-party Services: Elements like Cloudinary for file handling and any other integrations (as seen in the “cloudinary” adapters and utilities).
b. Relationships & Interactions:
• The Frontend issues HTTP/REST (and likely WebSocket) requests to the Backend API for most application logic like user authentication, course management, messaging, and quiz data.
• The Backend interacts directly with the Persistence Layer (via repositories) to store and retrieve entities (course, assignment, user, etc.).
• When real-time collaboration is needed (e.g., meetings), the Backend or the Frontend connects with the Livekit Server to establish audio/video conference sessions.
• Similarly, for whiteboarding or drawing interactions during a meeting, the UI communicates with the tldraw Server.
• Docker Compose ties these services together by managing inter-container communication and deployment configurations.
c. Architectural Patterns & Design Principles:
• Use a layered (or MVC-style) design on the backend with clear separation between controllers, services, mappers, and repositories.
• The frontend is component-based and structured per feature (e.g., courses, meeting, chat, dashboard).
• Integration through APIs and WebSockets for real-time updates.
• Containerized deployment, ensuring that each major service (backend API, meeting server, whiteboard server) is independently deployable and scalable.
d. Relevant Technologies & Frameworks:
• Java Spring Boot, Maven for the backend.
• Docker (Dockerfiles and docker-compose) for container orchestration.
• Next.js (React) for the frontend UI.
• LiveKit (Go) for real-time meeting/video collaboration.
• tldraw (Node/TypeScript based) for whiteboard collaboration.
• Cloudinary for file uploads and multimedia management.
• Various libraries for state management (Redux) and UI components.
• RESTful API interactions between the UI and Backend.
• WebSocket communication channels for real-time interactions (chat, meeting events).
• How container orchestration via docker-compose binds these services together.
• Intermediary adapters or utilities (such as Cloudinary or messaging adapters) that connect to external systems.
• “Database” (representing persistence via repositories).
• “Livekit Server (Go)” for meeting and video interactions.
• “tldraw Server” for whiteboard sessions.
• “External Cloud Service (Cloudinary)” for file storage (optional).
• Optionally, illustrate a “Docker Compose” container that groups the Backend, Livekit, and tldraw components, indicating container orchestration.