Roadmap · Foundations
MongoDB (Python)
Opens with creditsFor students and early-career engineers who want to use MongoDB properly from JavaScript, Python or Java, not just store JSON in it. By the end you can query and change documents confidently, model data around your queries, index and aggregate with evidence, and run MongoDB safely from application code.
By the end, you will be able to
- Write correct queries and updates with query operators, update operators, arrays and nested fields in mongosh, and explain why each matches the documents it does
- Model data around your application's queries, choose between embedding and referencing, and apply the common schema design patterns with a validation rule to protect them
- Read explain() output, design compound indexes with the ESR guideline and prove the speed-up with before-and-after numbers
- Build reports with the aggregation pipeline, including $group, $unwind, $lookup and $facet, and know its memory and size limits
- Use MongoDB from your code with one shared client, safe filters, range-based pagination, the right write concern and transactions where they are genuinely needed
The path
8 stages, in the order to learn them. Open one to start.
1Documents and your setupLearn what documents, BSON and collections are and when MongoDB is the right fit, then set up a free Atlas cluster or a local server with mongosh and Compass, and load a sample dataset to practise on.8 topics · ~2 weeks
- 1Documents, fields and the document modelMongoDB stores data as documents: records made of field and value pairs that look like JSON objects.
- 2When MongoDB fits, and when it does notMongoDB fits data that is read and written as whole units: a product with its variable attributes, a user profile, an event log, content with nested sections.
- 3BSON and data typesMongoDB does not store plain JSON.
- 4The _id field and ObjectIdEvery document has an
_idfield, its primary key, which must be unique within the collection and cannot be changed. - 5An Atlas free cluster or a local serverYou have two good ways to run MongoDB.
- 6mongosh, the MongoDB shellmongosh is the MongoDB shell: a command-line client where you type commands and see results.
- 7Compass as your GUICompass is MongoDB's free graphical tool.
- 8Loading a sample datasetPractise on realistic data from day one.
8 in this stageOpen this stage2Reading and writing documentsInsert, find, update and delete documents in mongosh: filter with query operators, shape results with projection, sort and limit, change fields with update operators, and know when to upsert or replace.9 topics · ~2 weeks
- 1Inserting documentsAdd documents with
insertOnefor one andinsertManyfor an array of them. - 2find, findOne and equality filters
find(filter)returns every document that matches the filter, andfindOne(filter)returns the first match or null. - 3Comparison and logical query operatorsQuery operators start with
$and go inside a field's value. - 4Projection: choosing the fields you get backThe second argument to
findis a projection, which chooses the fields returned. - 5Sorting, skip, limit and cursors
findreturns a cursor, an object that fetches results in batches as you read them, rather than the whole result at once. - 6updateOne, updateMany and update operators
updateOne(filter, update)changes the first matching document andupdateManychanges all of them. - 7UpsertsAn upsert updates the matching document, or inserts a new one if none matches.
- 8Replacing versus updating
replaceOne(filter, doc)swaps the whole document for a new one, keeping only_id. - 9Deleting documents safely
deleteOne(filter)removes the first match anddeleteMany(filter)removes all of them, returningdeletedCount.
9 in this stageOpen this stage- 1Inserting documentsAdd documents with
- Arrays and nested documentsQuery and update fields inside nested documents and arrays with dot notation, $elemMatch and the array and positional update operators, and learn why the 16 MB document limit shapes your design.6 topics · ~2 weeksOpens with credits
- Data modelling and schema designDesign documents around the queries your application runs: choose between embedding and referencing by cardinality, apply the common schema design patterns, avoid unbounded arrays and protect the design with $jsonSchema validation.8 topics · ~3 weeksOpens with credits
- Indexes and query plansLearn how MongoDB indexes work, read explain() output, design compound indexes with the ESR guideline, use multikey, unique, partial and TTL indexes, and prove each improvement with measurements.9 topics · ~2 weeksOpens with credits
- The aggregation pipelineBuild reports with the aggregation pipeline: filter with $match, total with $group and accumulators, flatten arrays with $unwind, join with $lookup, run several reports at once with $facet, save results with $merge, and know the pipeline's limits.9 topics · ~3 weeksOpens with credits
- MongoDB from your codeUse MongoDB from your language with one shared client, typed models, safe filters, proper handling of duplicate key errors and range-based pagination, and know what retryable writes and change streams do for you.8 topics · ~3 weeksOpens with credits
- Transactions, replication and operationsUnderstand replica sets, write concern, read concern and read preference, use multi-document transactions only where they are needed, see how sharding and shard keys work, and handle users, network access, backups and monitoring.9 topics · ~3 weeksOpens with credits
6 more stages, 49 more topics, free with an account.
You have seen the open stages of the MongoDB roadmap. Every topic it covers is listed above, and an account opens the rest: what each topic means, a question to check yourself, the courses, the practice and Tauseef's advice for every stage. Early access is open: sign up and your account is active shortly after.
Everything here is free to learn from. A few things, like adding a roadmap, keeping a cheat sheet or asking Tauseef a question, use credits. You get 15 when you join, your first roadmap is free, and if you are learning seriously and run out, you can ask for more. Credits only make sure the platform goes to people who are actually learning.
Build a project
A finished project proves more than a certificate.
- Start with this oneintermediate1 semester · 2 studentsMulti-Vendor Product Catalogue with Faceted Search on MongoDB
Products with varied attributes, the extended reference pattern and a $facet search page with real indexes
- MongoDB (Atlas free cluster or local)
- Node.js with the MongoDB driver
- Next.js or React
- mongosh and Compass
- k6 or autocannon for load tests
- intermediate1 semester · 2 studentsTeam Chat App with Threads and Read Receipts on MongoDB
Tests modelling without unbounded arrays, range-based pagination and change streams for live messages
- MongoDB replica set (Atlas free cluster)
- Node.js with Socket.IO or WebSockets
- MongoDB Node.js driver or Mongoose
- React or Next.js
- k6 for load tests
- intermediate1 semester · 2 to 3 studentsIoT Sensor Readings Store with Bucketed Time Series in MongoDB
The bucket pattern, TTL indexes and aggregation over millions of readings, with measured results
- ESP32 with DHT22 or DS18B20 sensors
- MQTT (Mosquitto)
- Node.js or Python ingestion service
- MongoDB time series collections
- React or Next.js dashboard
Related on Sefism
Picked from the other libraries by shared topics.
Best practices
See all- PostgreSQL Best PracticesDesign, index, query and run PostgreSQL well: data types, constraints, EXPLAIN, zero-downtime migrations, pooling, transactions, backups and roles.
- MongoDB Best PracticesModel, index, query and run MongoDB well: access-pattern schemas, validation, the ESR rule, aggregation limits, write concern, transactions, drivers and security.
- Data Pipeline Best PracticesHow to build data pipelines you can re-run, test and trust: idempotent tasks, orchestrator hygiene, layered transformations, data tests, freshness, ownership and monitoring.
Checklists
See allProject structures
See all- NestJS project structureFor people who want a structured TypeScript backend with clear rules about where code goes. Every feature is a Nest module that owns its controller, service, DTOs, entities and tests, so the app grows by adding folders, not by stretching old ones. The tree follows one orders API from nest new to a codebase a whole team can run for years.
- FastAPI project structureA typed Python API for an orders app, built the way the FastAPI docs and the official full stack template lay it out: one
apppackage, a router per feature, Pydantic schemas at the edges, services in the middle and SQLAlchemy models with Alembic migrations underneath. For students who have finished the FastAPI tutorial and want to know where the second, tenth and fiftieth file go. - Django project structureFor students building their first serious Python web app or API with Django, and for the team that keeps it running years later. The project is a thin "config" package plus one Django app per business area (accounts, catalog, orders, core), each owning its models, services, views, API, migrations and tests. Settings come from validated environment variables, and the tree grows from the tutorial layout to CI, containers, observability and enforced module boundaries.
Career questions
See all- Should I use PostgreSQL or MongoDB for my project?For most student and startup projects, PostgreSQL is the safer default: relational data, joins, constraints and transactions fit most apps, and it handles JSON and vector search too. MongoDB is a good fit when your data is naturally document-shaped and varies a lot, or your team already knows it well. Model your data first, then choose.
- Should I use Firebase or Supabase for my app?Both let you ship an app fast with auth, a database, storage and hosting-style services. Supabase is built on PostgreSQL, so it suits relational data and SQL skills you will reuse anywhere. Firebase is a mature Google platform with a document database and strong mobile tooling. Choose by your data shape, your platform, and how much you want to learn transferable database skills.
- Do I need a vector database for my AI project?Often not. For a student project or a small app, a vector extension on a database you already use (such as pgvector in PostgreSQL), or even an in-memory index, is enough. A dedicated vector database earns its place with very large collections, heavy query traffic, or features like advanced filtering and multi-tenancy at scale.
Cheat sheets
See all- Choosing the right database cheat sheetSQL, document, cache, search, vector and more.
- SQL and databases cheat sheetQueries, design, indexes, transactions.
- Vector databases cheat sheetEmbeddings, similarity metrics, ANN indexes, filtering, hybrid search, reranking, RAG chunking, pgvector, dedicated stores and evaluation.
Stuck on something specific?
Writing only gets you so far. If you want an answer to your situation rather than the general case, book a session and we will work through it together. Sessions are free for approved Sefism members, and a few slots open each week.
- 1:1 Mentorship
- Fresh Graduate Mentorship
- Career Guidance
Brand deals, promos and partnerships: tauseeffayyaz@gmail.com