-
Type: Improvement
-
Resolution: Fixed
-
Priority: Major - P3
-
Affects Version/s: None
-
Component/s: None
-
None
-
Storage Execution NAMER
-
Fully Compatible
-
Execution Team 2023-06-12, Execution NAMR Team 2023-06-26, Execution NAMR Team 2023-10-02, Execution NAMR Team 2023-10-16
It is not safe to write to collection or index catalog entry instances in commit handlers. Cloned instances as part of DDL operations can be returned to other threads doing lock-free reads after the DDL operation is committed to the storage engine but before its commit handlers have run. Any such write requires synchronization and goes against the design philosophy that readers should obtain immutable instances that are fully in sync with the opened storage snapshot.
To help find and prevent future misuse we should consider publishing new collection instances in the first commit handler rather than the last.
- depends on
-
SERVER-77062 Perform copy-on-write of index catalog entries when cloning a collection
- Closed
- duplicates
-
SERVER-77130 Fix data races when writing to collection instances in commit handlers
- Closed
- related to
-
SERVER-81297 Simplify CollectionIndexUsageTracker
- Closed