[JAVA-1939] Support automatically setting _id in Upserts. Created: 27/Aug/15 Updated: 14/Jan/19 Resolved: 14/Jan/19 |
|
| Status: | Closed |
| Project: | Java Driver |
| Component/s: | Codecs |
| Affects Version/s: | None |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Minor - P4 |
| Reporter: | Ross Lawley | Assignee: | Unassigned |
| Resolution: | Won't Fix | Votes: | 1 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Description |
|
If I have a collectible codec, we could in theory set the _id for upserts that insert by automatically including it in $setOnInsert. Would require a change to CollectableCodec so that the `_id` generation is publicly accessible and doesn't rely on an document instance. |