[SERVER-13034] Rename "upserted" field to "inserted" in update command reply Created: 04/Mar/14 Updated: 06/Dec/22 |
|
| Status: | Backlog |
| Project: | Core Server |
| Component/s: | Write Ops |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Major - P3 |
| Reporter: | Mathias Stearn | 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
|
||||||||||||
| Backwards Compatibility: | Minor Change | ||||||||||||
| Participants: | |||||||||||||
| Description |
|
This would allow us to report the _ids generated by insert on the server using the same field name in the future. |
| Comments |
| Comment by David Storch [ 09/Mar/16 ] |
|
You're right. I'll leave it linked to |
| Comment by J Rassi [ 09/Mar/16 ] |
|
Dave, I don't think you're referring to the same thing that Mathias is. If I understand correctly here, Mathias is suggesting that the update command response field called "upserted" (which is the equivalent of the getLastError command response "upserted") be renamed to "inserted", and you're suggesting that the profiler field called "upsert" (and the per-operation diagnostic log entry field of the same name) be removed in favor of the existing field "ninserted". |
| Comment by David Storch [ 09/Mar/16 ] |
|
As an alternative, we are thinking of removing the "upserted" field and instead setting "ninserted" to 1 when an upsert:true update results in an insert. |