mongodb query index 分析


query 的过程及分析:web

query 是经过Query planner选择最有效的查询plan ,为一个query 被给予一个可用的索引,查询时 query optimizer(最优的查询条件选择器)在caches里面查询, 找出匹配的最优的查询的index(query shapes),the query planner 搜索query plan cache寻找合适的query shapse ,若是没有合适的index,the query planner生成一个备用的plans,在对这个 plans 进行评估,在选则一个winning plan,在建立一个Cache entry 最后返回一个Result Documents.
plan cache是经过脚本的触发器去改变的分布式

 

 

 

 

 

 

plan cache Flushes spa

在关闭计算机的状况下,plan cache 将会消失,不在会保blog

planCache.clear()及PlanCache.clearPlansByQuery()能够清除cache索引

分布式查询it

相关文章
相关标签/搜索