[SERVER-58738] Update command response does not properly reflect number of documents updated when updating a document fails due to exceeding the BSON size limit Created: 21/Jul/21 Updated: 18/Jul/23 |
|
| Status: | Backlog |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Gregory Noma | Assignee: | Backlog - Query Execution |
| Resolution: | Unresolved | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
|||||||||||||||||||||||
| Assigned Teams: |
Query Execution
|
|||||||||||||||||||||||
| Operating System: | ALL | |||||||||||||||||||||||
| Steps To Reproduce: |
|
|||||||||||||||||||||||
| Sprint: | QE 2021-08-23, QE 2021-09-06, QE 2021-09-20, QE 2021-10-04, QE 2021-10-18, QE 2021-11-01, QE 2021-11-15, QE 2021-11-29, QE 2021-12-13, QE 2021-12-27, QE 2022-01-10, QE 2022-04-04, QE 2022-03-21, QE 2022-01-24, QE 2022-04-18, QE 2022-05-02, QE 2022-05-16, QE 2022-05-30 | |||||||||||||||||||||||
| Participants: | ||||||||||||||||||||||||
| Description |
|
When attempting to update a document fails due to exceeding the BSON size limit, the number documents that were successfully updated before reaching the failing document are not reflected in the update command response; instead, it reports that 0 documents were updated. I have not tested whether this affects other types of write errors as well. |
| Comments |
| Comment by Romans Kasperovics [ 11/Mar/22 ] |
|
I have tried some relevant commands, and they show transactional behaviour (restore the state on error):
In contrast, db.command({update: "coll", updates: [ { ..., multi: true}]}); updates a part of the collection until it hits an error based on the matching order. Such a behaviour is common for imperative programming languages, but not for databases for few reasons. Is it intended? Or perhaps legacy? |
| Comment by Romans Kasperovics [ 08/Feb/22 ] |
|
kyle.suarez, david.storch: no, my fix for
|
| Comment by Kyle Suarez [ 08/Feb/22 ] |
|
romans.kasperovics could you please check if your work in |
| Comment by Ana Meza [ 23/Jul/21 ] |
|
Kyle, could you please look for similar tickets? |