10. Your replica set is regularly under heavy load and your business analysis team would like to perform analytic queries to track goals. The fields they plan to query on are currently not indexed. What is the best resolution to help them in their job function? Choose the best answer:
Answer options
- A.Redesign the schema so the data they plan to query is indexed
- B.Create a separate cluster that syncs from the original cluster every night for analytic queries
- C.Create views that they can query in lieu of running their own aggregations
- D.Help them set up an automatic job that runs at 3 AM every Friday
- E.Create specialized indexes for them on a dedicated secondary
Answer confidence: Medium
Correct answer: E
Explanation language: Chinese
分析型查询应在不影响线上主节点读写的前提下运行,最合适的做法是把它们导到专门的从节点(专用/hidden secondary)上并为其建好所需索引(D)。A 建视图不会让未索引字段的聚合变快;B 每天同步一个新集群成本高、数据还滞后一天,不是“帮助他们完成工作”的最优解;C 为分析查询重做线上 schema 代价过大;E 定时跑批只是把问题挪到凌晨,负载依然存在。