mongo icon indicating copy to clipboard operation
mongo copied to clipboard

SERVER-78113: not cache meaningless plan, it will increased memory overhead and increase computing overhead.

Open y123456yz opened this issue 1 year ago • 1 comments

// when the mode is PlanCachingMode::AlwaysCache or PlanCachingMode::SometimesCache, there is a special case.
// take Classic plan cache for example:
//   If the winning index's advanced = 0 && works == 1 && isEOF == true, which means we didn't get any data to rank score, all candidates 
//   score is same. the score of the calculation is meaningless.
//
//In this case, if we cache the plan, it will increased memory overhead. when the cached plan stage pick best plan, 
//it will trigger replan. this will increase computing overhead.

y123456yz avatar Jun 15 '23 06:06 y123456yz

https://jira.mongodb.org/browse/SERVER-78113

y123456yz avatar Jun 15 '23 07:06 y123456yz