[SERVER-47233] WriteOp can be left in pending state, leading to erroneous NoProgressMade write error from mongos Created: 01/Apr/20 Updated: 29/Oct/23 Resolved: 07/Apr/20 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Sharding, Write Ops |
| Affects Version/s: | 4.2.3 |
| Fix Version/s: | 4.2.6, 4.4.0-rc0, 4.0.19, 4.7.0 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Max Hirschhorn | Assignee: | Marcos José Grillo Ramirez |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | PM-1645-Milestone-1 | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||||||||||
| Backwards Compatibility: | Fully Compatible | ||||||||||||||||||||
| Operating System: | ALL | ||||||||||||||||||||
| Backport Requested: |
v4.4, v4.2, v4.0
|
||||||||||||||||||||
| Sprint: | Sharding 2020-04-20 | ||||||||||||||||||||
| Participants: | |||||||||||||||||||||
| Linked BF Score: | 17 | ||||||||||||||||||||
| Description |
|
The changes from d591387 as part of For updateOne by _id operations which target all shards that may own data for the collection, this can lead to a WriteOp being put in the WriteOpState_Pending state without scheduling more work on the ARS. Since BatchWriteOp::noteBatchResponse() must be called to transition the WriteOp to the WriteOpState_Completed or WriteOpState_Error states and that only happens when getting a response from the ARS, the WriteOp is left stranded in the WriteOpState_Pending state until it exhausts the numRoundsWithoutProgress counter.
|
| Comments |
| Comment by Githook User [ 08/Apr/20 ] |
|
Author: {'name': 'Marcos José Grillo Ramírez', 'email': 'marcos.grillo@mongodb.com', 'username': 'm4nti5'}Message: (cherry picked from commit 2f6cac5d4b98969621b48decd2cadaed9e8faf14) |
| Comment by Githook User [ 08/Apr/20 ] |
|
Author: {'name': 'Marcos José Grillo Ramírez', 'email': 'marcos.grillo@mongodb.com', 'username': 'm4nti5'}Message: (cherry picked from commit 2f6cac5d4b98969621b48decd2cadaed9e8faf14) |
| Comment by Githook User [ 07/Apr/20 ] |
|
Author: {'name': 'Marcos José Grillo Ramírez', 'email': 'marcos.grillo@mongodb.com', 'username': 'm4nti5'}Message: (cherry picked from commit 2f6cac5d4b98969621b48decd2cadaed9e8faf14) |
| Comment by Githook User [ 07/Apr/20 ] |
|
Author: {'name': 'Marcos José Grillo Ramírez', 'email': 'marcos.grillo@mongodb.com', 'username': 'm4nti5'}Message: |
| Comment by Marcos José Grillo Ramirez [ 02/Apr/20 ] |
|
The assurances of the batch write executor were the following before
With |