[SERVER-81980] Make PreImagesTruncateManager avoid calling abandonSnapshot while holding a Collection Snapshot Created: 09/Oct/23 Updated: 07/Feb/24 |
|
| Status: | In Code Review |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Haley Connelly | Assignee: | Haley Connelly |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | tech-debt | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||||||
| Sprint: | Execution EMEA Team 2023-10-30, CAR Team 2023-11-13, CAR Team 2023-11-27, CAR Team 2023-12-11, CAR Team 2023-12-25, CAR Team 2024-01-08, Execution Team 2024-02-19, CAR Team 2024-01-22, CAR Team 2024-02-05 | ||||||||||||||||||||
| Participants: | |||||||||||||||||||||
| Linked BF Score: | 120 | ||||||||||||||||||||
| Description |
|
The pre image truncate marker initialization code relies on abandonSnapshot() to provide an updated view of the pre-images collection, and update the highest seen recordId and wall time for each nsUUID. However, (1) the code passes a CollectionAcquisition reference whose underlying collection pointer could be invalidated by calling abandonSnapshot() if there were a concurrent DDL operation. At this time, the uses of abandonSnapshot() are called while holding the collection lock, which prevents DDL operations from coming in and invalidating the Collection snapshot. |