[SERVER-71594] Use pending namespaces map to discover catalogId when openCollection is called without timestamp Created: 23/Nov/22  Updated: 29/Oct/23  Resolved: 30/Nov/22

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 6.3.0-rc0

Type: Task Priority: Major - P3
Reporter: Henrik Edin Assignee: Will Buerger
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Backwards Compatibility: Fully Compatible
Sprint: Execution Team 2022-12-12, Execution Team 2022-11-28
Participants:

 Description   

When openCollection is called without a timestamp, the regular catalogId mapping may be stale if there is a concurrent DDL commit in progress, such as a collection rename.

We can instead use the pending namespace map and extract the catalogId from the collection instance that we are in progress of committing. 

If the pending namespace is a drop and we don't have a collection to get the catalogId from we can fallback to use the regular mapping. If we find an entry using it we know that our snapshot cannot see the drop.



 Comments   
Comment by Githook User [ 30/Nov/22 ]

Author:

{'name': 'Will Buerger', 'email': 'will.buerger@mongodb.com', 'username': 'wbuerger46'}

Message: SERVER-71594: Use pending namespaces map to discover catalogId when openCollection is called without timestamp
Branch: master
https://github.com/mongodb/mongo/commit/dc19a081f8649fdd870c346f7e1d51054bcc1c44

Generated at Thu Feb 08 06:19:27 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.