MongoDB DBA · Question 174 · Multiple choice

59. Consider a sharded collection that uses a hashed shard key. Which of the following is true regarding queries and new document inserts on this collection? Check all that apply:

Answer options

  1. A.
    New document inserts are more likely to be evenly distributed among shards.
  2. B.
    Queries using the shard key must use at least one additional key-value pair.
  3. C.
    Range queries on the shard key are more likely to be Broadcast Operations.

Answer confidence: High

Correct answer: A, C

Explanation language: Chinese

哈希分片键把字段值哈希后再分布,新插入的文档更容易均匀落到各分片(A);但哈希破坏了值的顺序性,对分片键做范围查询无法定位 chunk,只能作为广播操作(C)。B 错误:哈希分片键上单字段的等值查询仍可定向路由,不需要再附加其它字段。

Papers containing this question

This question appears in 3 bank records. Public pages combine identical prompts and options. Selected questions display the highest-confidence record; the others show a short preview. Paper-based learning preserves each record's answer, explanation, and confidence.

AUTHOR · PROJECTS · OPEN SOURCE

Author & MongoDB projects

Building data platforms, MongoDB migration and sync tools, and cloud operations products.

Contact the author for any MongoDB needs.

Contact the author ↗mlhp123@outlook.com

Support the author

If this question bank helps you, optional donations are welcome.

Scan with Alipay to support the authorOpen full-size donation image ↗