What I Learned Building a Production LMS with Node.js, MongoDB & AWS in 2026
Building an LMS looks simple at the beginning. You need users, classes, payments, attendance, recordings, homework, notifications, and reports. Then you move into production. Suddenly, you are dealing with authentication, permissions, concurrent requests, payment verification, background jobs, database indexes, cloud costs, logging, deployments, backups, and uptime. I have been working on a…
Building a production Learning Management System (LMS) using Node.js, MongoDB, and AWS proved to be more complex than initially anticipated. The project required handling various components such as user authentication, permissions, concurrent requests, payment verification, background jobs, and database indexing, among others. The author shares their experiences, lessons learned, and recommendations for future development.
The architecture of the LMS, which includes Node.js NestJS, MongoDB, AWS services, and external APIs, was deemed effective. However, what truly matters is how the system is designed around this technology. The author emphasizes the importance of proper system design over the choice of technologies.
Regarding Node.js, the author confirms that it can handle a serious production system with a large amount of I/O work. However, performance problems typically arise from poor database queries, missing indexes, excessive database round trips, unnecessary API calls, blocking work within request handlers, poor background job design, large payloads, weak caching strategies, and slow APIs. The author stresses the importance of addressing these issues before considering a technology stack replacement.
When using MongoDB, the author recommends avoiding treating schema design as optional. Instead, they advocate for dedicated collections to manage data growth and facilitate indexing, querying, and archiving. Proper database architecture is essential, even when working with MongoDB.
The attendance system in an LMS is more complex than it seems. It involves handling various factors such as class start time, student join time, late arrival, and session validity. To prevent duplicate attendance records under concurrent requests, the author suggests protecting the invariant at the database level by creating a unique index on the student, class, and session fields.
Payments in the LMS must be idempotent, meaning that the system should handle multiple payment callbacks without causing any issues. The author advises storing a unique reference from the payment provider and enforcing uniqueness at the database level to avoid processing the same transaction multiple times.
In summary, building a production LMS with Node.js, MongoDB, and AWS presented numerous challenges. The author shares their technical decisions, the problems they encountered as the system grew, and offers guidance on improving system design, database queries, attendance handling, and payment processing.
Written by urgent.news from Dev.to's reporting — not their text. Machine-written — it may contain errors, so check the original before relying on it.