[SERVER-61628] Do not reschedule range deletion task when numDeleted < numDocsToRemovePerBatch Created: 19/Nov/21  Updated: 29/Oct/23  Resolved: 09/Dec/21

Status: Closed
Project: Core Server
Component/s: Sharding
Affects Version/s: 5.2.0, 5.1.0, 4.4.10, 5.0.4
Fix Version/s: 5.3.0, 5.0.6, 4.4.11, 5.2.1

Type: Bug Priority: Major - P3
Reporter: Pierlauro Sciarelli Assignee: Pierlauro Sciarelli
Resolution: Fixed Votes: 0
Labels: range-deleter
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Related
Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Requested:
v5.2, v5.0, v4.4
Sprint: Sharding EMEA 2021-12-13
Participants:

 Description   

Currently, when the last documents in an orphan range have been deleted, the range deletion task gets re-enqueued and re-executed because of this condition. The next execution for the range simply finds no documents, and the range deletion task's document gets deleted.

As a result, if there are thousands of range deletion tasks, it's difficult to monitor the progression because hours/days could pass from the moment an orphaned range is cleared up and the moment its range deletion task's document is deleted.



 Comments   
Comment by Githook User [ 24/Jan/22 ]

Author:

{'name': 'Pierlauro Sciarelli', 'email': 'pierlauro.sciarelli@mongodb.com', 'username': 'pierlauro'}

Message: SERVER-61628 Do not reschedule range deletion task when orphans have been fully deleted
Branch: v5.2
https://github.com/mongodb/mongo/commit/942c7259628af723f70ea88c124a7c713a88fdf9

Comment by Githook User [ 14/Dec/21 ]

Author:

{'name': 'Pierlauro Sciarelli', 'email': 'pierlauro.sciarelli@mongodb.com', 'username': 'pierlauro'}

Message: SERVER-61628 Do not reschedule range deletion task when orphans have been fully deleted
Branch: v4.4
https://github.com/mongodb/mongo/commit/02be742d686fa668a8cc1d3d4d7c4f8fa678d521

Comment by Githook User [ 14/Dec/21 ]

Author:

{'name': 'Pierlauro Sciarelli', 'email': 'pierlauro.sciarelli@mongodb.com', 'username': 'pierlauro'}

Message: SERVER-61628 Do not reschedule range deletion task when orphans have been fully deleted
Branch: v5.0
https://github.com/mongodb/mongo/commit/83d6ea236b8177a21a08ba6acfc98e43a32f883c

Comment by Githook User [ 09/Dec/21 ]

Author:

{'name': 'Pierlauro Sciarelli', 'email': 'pierlauro.sciarelli@mongodb.com', 'username': 'pierlauro'}

Message: SERVER-61628 Do not reschedule range deletion task when orphans have been fully deleted
Branch: master
https://github.com/mongodb/mongo/commit/22db4d5e65c133424c13e7f4cdb2285846ab75ea

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