Courseiva
Data Modeling →mediumMultiple Choice

C100DEV Data Modeling Practice Question

A social media platform stores user profiles in a `users` collection. Each user document includes a `followers` array of user IDs. For highly popular accounts, this array has grown to over 2 million entries, causing documents to approach the 16 MB BSON limit and slowing read operations. The application frequently displays a user's follower count and the first 20 followers. Which schema design change best addresses this issue?

⚠ Common exam trap

The trap here is assuming that any large array must be fully normalized or moved to GridFS, rather than recognizing that the Outlier Pattern preserves fast access to the common subset while isolating the overflow.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

✓

Use the Outlier Pattern: store the first 1000 followers in the user document and flag the document as an outlier; store remaining followers in a separate `followers` collection keyed by user ID.

The Outlier Pattern is specifically designed to handle documents that grow beyond typical limits due to a few outliers. By embedding only a subset of followers and storing the rest separately, the design keeps the common case fast while accommodating the extreme case. This maintains the ability to quickly show the follower count and first 20 followers without hitting the 16 MB limit.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • ✗

    Convert the `followers` array to a GridFS bucket to store the list of follower IDs as a binary blob.

    Why it's wrong here

    GridFS is intended for storing large files exceeding 16 MB, not for structured arrays of user IDs. Using GridFS would make it impossible to efficiently query or update individual followers, and retrieving the first 20 followers would require reading and parsing the entire blob. This adds unnecessary complexity and does not support the application's read patterns.

  • ✗

    Normalize the schema by moving the entire `followers` array into a separate `followers` collection with one document per follower relationship.

    Why it's wrong here

    While normalization avoids document growth, it requires an additional query to retrieve even the first 20 followers and the follower count, which slows the common read path. The application frequently displays the follower count and first 20 followers; a fully normalized approach would require aggregation or multiple queries, increasing latency and complexity. The Outlier Pattern better balances the common case.

  • ✓

    Use the Outlier Pattern: store the first 1000 followers in the user document and flag the document as an outlier; store remaining followers in a separate `followers` collection keyed by user ID.

    Why this is correct

    The Outlier Pattern is designed for documents that exceed typical size limits due to a small number of outliers. By embedding only a subset of followers and flagging the document, the common case remains fast while the full list is accessible via a separate collection. This directly resolves the 16 MB limit and performance degradation while preserving the ability to show the first 20 followers and count.

  • ✗

    Apply the Attribute Pattern by converting the `followers` array into a set of key-value pairs where each follower ID is a field name.

    Why it's wrong here

    The Attribute Pattern is used for documents with many similar fields that share common characteristics, not for large arrays of scalar values. Converting follower IDs to field names would create an enormous number of fields, still exceeding the 16 MB limit and making queries inefficient. It does not address the root cause of unbounded array growth.

About these practice questions

This C100DEV question is part of Courseiva's 259-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written and reviewed by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

Last reviewed September 2026 · checked against the official MongoDB exam blueprint

This C100DEV practice question is part of Courseiva's free MongoDB certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the C100DEV exam.