[CDRIVER-3230] command options not included in bson size estimate in opquery write commands Created: 11/Jul/19 Updated: 28/Oct/23 Resolved: 12/Aug/19 |
|
| Status: | Closed |
| Project: | C Driver |
| Component/s: | libmongoc |
| Affects Version/s: | 1.11.0 |
| Fix Version/s: | 1.15.0 |
| Type: | Bug | Priority: | Major - P3 |
| Reporter: | Samantha Ritter (Inactive) | Assignee: | Kevin Albertson |
| Resolution: | Fixed | Votes: | 1 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||
| Case: | (copied to CRM) | ||||||||||||
| Description |
|
We split bulk writes into batches by creating and sending smaller individual write commands with subsets of the bulk write. We do this by adding the bulk write bson documents to each new write command until that write command is "full", so that we don't exceed the max bson size specified by the server. However, as of C driver 1.11, we append the write concern to the write command after we have deemed it "full." This can lead to an invalid bson document that exceeds the max bson size when it reaches the server. This bug was introduced in this change: |
| Comments |
| Comment by Githook User [ 12/Aug/19 ] |
|
Author: {'name': 'Kevin Albertson', 'email': 'kevin.albertson@10gen.com', 'username': 'kevinAlbs'}Message: OP_QUERY batch splitting was not taking command options into account |
| Comment by Kevin Albertson [ 23/Jul/19 ] |
|
Hi dzacchi@amadeus.com, we're planning to address this in 1.15.0. |
| Comment by David Zacchi [ 22/Jul/19 ] |
|
This prevents our migration to MongoDB 4.0 as the only mongocxx version compatible is 3.4 using libmongoc 1.11 containing this issue. Please fix the libmongoc for us to be able to build our application with it. Thanks in advance. |