[SERVER-66813] Fix issue with batch deletion when inserting records to the change collection Created: 26/May/22 Updated: 09/Jul/22 Resolved: 08/Jul/22 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Task | Priority: | Critical - P2 |
| Reporter: | Rishab Joshi (Inactive) | Assignee: | Rishab Joshi (Inactive) |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | pm-2334-m1 | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Sprint: | QE 2022-07-11 | ||||||||
| Participants: | |||||||||
| Description |
|
When working on the ticket: The problem is with calling onBatchedWriteCommit, which calls logOplogEntries which further call logApplyOps and then ChangeCollection::writeToChangeCollection and ultimately to OpObserverImpl::onInserts. The OpObserverImpl::onInserts is called within the context of the BatchWrites and will go to and again try to add operation to the addBatchOperation here. This adding operation to the ongoing batch is what may be causing the issue (not fully articulated though). This whole workflow is called while we are inside the while loop that caused the tassert failure, here. The current change collection code adds a hack to mitigate this issue. The ticket is about coming up with the right set of actions to fix this issue. |
| Comments |
| Comment by Rishab Joshi (Inactive) [ 08/Jul/22 ] |
|
This issue will be fixed as part of the ticket The PR has been discarded as there was no consensus on having a custom insert method for the change collection.
|
| Comment by Josef Ahmad [ 06/Jul/22 ] |
|
Marking this ticket as related to |