[DRIVERS-2271] Omit upsert and multi options in update statements by default Created: 08/Apr/22  Updated: 01/Jun/23

Status: Backlog
Project: Drivers
Component/s: CRUD
Fix Version/s: None

Type: Spec Change Priority: Unknown
Reporter: Jeremy Mikola Assignee: Unassigned
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
is related to DRIVERS-2270 Use $$unsetOrMatches for upsert and m... Implementing
Driver Changes: Needed

 Description   

Summary

b6cdaa8 originally changed the CRUD spec's documentation for upsert from "default is false" to "default is to not send a value". There is no similar guidance for multi, as the CRUD spec doesn't discuss command construction.

That said, there were never downstream language tickets for the upsert documentation change. Some drivers (e.g. libmongoc) have historically specified false for both options in outgoing update commands, so not to rely on the server's default. At this point, it is unlikely the server defaults will ever change (it would be a significant BC break), so we should consider requiring drivers to omit these fields by default.

In turn, this would mean we can remove $$unsetOrMatches for these options throughout our spec tests, and spec test authors will no longer need to remember to use that syntax going forward.

Motivation

Who is the affected end user?

Drivers.

How does this affect the end user?

Outgoing update commands are more verbose and spec test authors must remember to use $$unsetOrMatches for update command assertions.

Is this issue urgent?

No.

Is this ticket required by a downstream team?

No.

Is this ticket only for tests?

No.


Generated at Thu Feb 08 08:25:09 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.