[SERVER-56438] Dispose of ReshardingDonorOplogIterator in ReshardingOplogApplier, even on cancellation Created: 28/Apr/21  Updated: 29/Oct/23  Resolved: 12/May/21

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

Type: Task Priority: Major - P3
Reporter: Max Hirschhorn Assignee: Max Hirschhorn
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Backwards Compatibility: Fully Compatible
Sprint: Sharding 2021-05-17
Participants:
Story Points: 2

 Description   

This isn't currently a bug because locally-executing Pipelines and DocumentSources do not dereference their OperationContext during dispose() and destruction. However, we have established a pattern in ReshardingCollectionCloner and ReshardingTxnCloner to run a task on the cleanup executor. We should do the same with ReshardingDonorOplogIterator in ReshardingOplogApplier.



 Comments   
Comment by Githook User [ 12/May/21 ]

Author:

{'name': 'Max Hirschhorn', 'email': 'max.hirschhorn@mongodb.com', 'username': 'visemet'}

Message: SERVER-56438 Add ReshardingDonorOplogIterator::dispose() method.

Guarantees that Pipeline underlying ReshardingDonorOplogIterator is
always disposed by ReshardingOplogApplier, even upon cancellation.
Branch: master
https://github.com/mongodb/mongo/commit/dbde3c8b9995d744f38051f6c7fba59e83e03a86

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