Courseiva
Indexing and Performance →hardMultiple Choice

C100DBA Indexing and Performance Practice Question

A sharded cluster experiences poor query performance because a targeted query targeting a specific shard key still results in a scatter-gather operation across all shards. What is the root cause?

⚠ Common exam trap

Candidates confuse 'querying by the shard key' with 'including the shard key in the query predicate.' Even if you know the shard key, the query must explicitly filter by it.

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

✓

The query predicate completely omitted the shard key or its valid prefix fields.

To target a specific shard directly, a query must include the exact shard key or a valid prefix of the shard key in its filter predicate. Omitting the shard key forces the mongos router to query every shard in the cluster to assemble the final result set.

Answer analysis

Option-by-option breakdown

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

  • ✗

    The chunk migration threshold was set too low, causing frequent balancing cycles across shards.

    Why it's wrong here

    Chunk balancing affects data distribution and migration overhead across cluster nodes, but it does not cause targeted queries to transform into scatter-gather operations. Routing behavior depends strictly on the presence of the shard key in the query predicate.

  • ✓

    The query predicate completely omitted the shard key or its valid prefix fields.

    Why this is correct

    Without the shard key or a valid prefix in the query filter, the mongos query router cannot determine which shard holds the matching data. Consequently, it must broadcast the query to all shards in the cluster, creating an inefficient scatter-gather operation.

  • ✗

    The collection was created as unhashed, preventing the mongos router from hashing query inputs.

    Why it's wrong here

    Whether a shard key uses hashed or ranged distribution, omitting the shard key from the query filter always results in a scatter-gather query. The choice of sharding strategy alone does not dictate query routing behavior when predicates lack key fields.

  • ✗

    The balancer process was paused, leaving uneven document distribution across cluster shards.

    Why it's wrong here

    An unbalanced cluster may cause some shards to handle heavier workloads than others, but queries that explicitly include the shard key will still route directly to the appropriate shard rather than executing cluster-wide scatter-gather requests.

About these practice questions

One of 222 original C100DBA practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. 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 C100DBA 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 C100DBA exam.