[SERVER-9306] Ability to temporarily forbid query optimizer from using index ("invisible index") Created: 09/Apr/13 Updated: 06/Dec/22 Resolved: 23/Apr/20 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Index Maintenance, Querying |
| Affects Version/s: | None |
| Fix Version/s: | 4.4.0-rc3, 4.7.0 |
| Type: | New Feature | Priority: | Major - P3 |
| Reporter: | Adam Flynn | Assignee: | Backlog - Query Team (Inactive) |
| Resolution: | Done | Votes: | 9 |
| Labels: | query_triage, storch | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||||||||||||||||||||||||||||||||||||||
| Assigned Teams: |
Query
|
||||||||||||||||||||||||||||||||||||||||||||||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||||||||||||||||||||||||||||||||||||||||||||||
| Backport Requested: |
v4.4
|
||||||||||||||||||||||||||||||||||||||||||||||||||||
| Sprint: | Query 2018-03-12, Query 2018-03-26, Execution Team 2020-03-09, Execution Team 2020-03-23 | ||||||||||||||||||||||||||||||||||||||||||||||||||||
| Participants: | |||||||||||||||||||||||||||||||||||||||||||||||||||||
| Case: | (copied to CRM) | ||||||||||||||||||||||||||||||||||||||||||||||||||||
| Linked BF Score: | 88 | ||||||||||||||||||||||||||||||||||||||||||||||||||||
| Description |
|
It would be helpful if there was a way to disable an index before dropping. Been clearing out some unused production indexes lately, but there's always a tense moment after issuing the dropIndex command where I wait to see if it was less "unused" than expected. If there was a way to just disable the index (semantics would be that it keeps getting updated, just can't be used by queries), then a revert would be much faster if something goes wrong and the drop could be done with more confidence. |
| Comments |
| Comment by Githook User [ 24/Apr/20 ] |
|
Author: {'name': 'Zhihui Fan', 'email': 'yizhi.fzh@alibaba-inc.com', 'username': 'zhihuiFan'}Message: Co-authored-by: Ruoxin Xu <ruoxin.xu@mongodb.com> (cherry picked from commit bad7c538e7efbc996a6089e1569681edf24e6b33) |
| Comment by Githook User [ 22/Apr/20 ] |
|
Author: {'name': 'Zhihui Fan', 'email': 'yizhi.fzh@alibaba-inc.com', 'username': 'zhihuiFan'}Message: Co-authored-by: Ruoxin Xu <ruoxin.xu@mongodb.com> |
| Comment by Daniel Gottlieb (Inactive) [ 26/Mar/20 ] |
|
My CR is complete with outstanding (but trivial) changes requested. Assigning back to query to follow up. |
| Comment by Ian Whalen (Inactive) [ 23/Feb/18 ] |
|
Assigning to david.storch to do an initial review of the PR for potential upgrade/downgrade complexities. |
| Comment by Ivan Artemov [ 20/Jan/18 ] |
|
I think, you need use "Invisible index" name in title |
| Comment by Adam Flynn [ 30/Mar/16 ] |
|
Thanks Asya - looks like that'll address this use-case nicely. |
| Comment by Asya Kamsky [ 30/Mar/16 ] |
|
Please note that for this particular described use case, 3.2 indexStats allows you to see the index usage. |