[SERVER-79533] BulkWriteReplyItem should only expose upsertedId rather than using write_ops::Upserted Created: 31/Jul/23 Updated: 29/Oct/23 Resolved: 29/Aug/23 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | None |
| Affects Version/s: | None |
| Fix Version/s: | 7.1.0-rc0 |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Kaitlin Mahar | Assignee: | Frederic Vitzikam |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | milestone-1 | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Assigned Teams: |
Replication
|
| Backwards Compatibility: | Fully Compatible |
| Sprint: | Repl 2023-09-04 |
| Participants: |
| Description |
|
Right now BulkWriteReplyItem uses the write_ops::Upserted type to expose information about upserts. However, the Upserted type stores both an index as well as an _id. This makes sense in the context of the update command, since the Upserted type there is a top-level field on the command response and users need a way to map the upsert info back to the input operations. But in bulkWrite, we are returning this info in the per-statement responses, so it is redundant to include the index. We should just expose the upsertedId instead. |
| Comments |
| Comment by Githook User [ 25/Aug/23 ] |
|
Author: {'name': 'Frederic Vitzikam', 'email': 'frederic.vitzikam@mongodb.com', 'username': 'fredvitz'}Message: |