[SERVER-44949] listIndexes on config.system.sessions does not return correct indexes Created: 04/Dec/19  Updated: 27/Oct/23  Resolved: 03/Dec/21

Status: Closed
Project: Core Server
Component/s: Sharding
Affects Version/s: 3.6.16, 4.2.2, 4.0.14
Fix Version/s: None

Type: Bug Priority: Major - P3
Reporter: Cheahuychou Mao Assignee: [DO NOT USE] Backlog - Sharding Team
Resolution: Gone away Votes: 0
Labels: tommaso-triage
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
is related to SERVER-45102 Sharded listIndexes should always tar... Closed
Assigned Teams:
Sharding
Operating System: ALL
Participants:

 Description   

The only sharded collection which has the config server as the primary shard is config.system.sessions. Unfortunately, the code path that the config server calls to create indexes on the sessions collection would currently invariant if one of the targeted shards was the config server itself. To get around this, index commands do not target the config shard, but as a result, listIndexes on config.system.sessions will not return the correct indexes. This bug existed prior to 4.4 as well, since the old code to create indexes on the sessions collection also did not build the index on the config server.



 Comments   
Comment by Tommaso Tocci [ 03/Dec/21 ]

I double check and jack.mulrow was right, we now correctly return the indexes for config.system.sessions

Comment by Jack Mulrow [ 20/Dec/19 ]

Note that SERVER-45102 changed listIndexes to always target the shard that owns the $minKey chunk, so this problem may have gone away in master.

Generated at Thu Feb 08 05:07:26 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.