Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion docs/migration-2.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -503,7 +503,7 @@ mongo.WithSession(context.TODO(),sess,func(ctx context.Context) error {

## Options Package

`ClientOptions.AuthenticateToAnything` was marked for internal use in 1.x and does not have a replacement.
`ClientOptions.AuthenticateToAnything` was removed in v2 (it was marked for internal use in v1).

The following fields were removed because they are no longer supported by the server

Expand Down Expand Up @@ -633,10 +633,16 @@ The following types are not valid for a `findOne` operation and have been remove
- `MaxAwaitTime`
- `NoCursorTimeout`

### FindOneAndUpdateOptions

The `ArrayFilters` struct type has been removed in v2. As a result, the `ArrayFilters` field in the `FindOneAndUpdateOptions` struct now uses the `[]interface{}` type. The `ArrayFilters` field (now of type `[]interface{}`) serves the same purpose as the `Filters` field in the original `ArrayFilters` struct.

### UpdateManyOptions / UpdateOneOptions

The `UpdateOptions` has been separated into `UpdateManyOptions` and `UpdateOneOptions` to configure the corresponding `UpdateMany` and `UpdateOne` operations.

The `ArrayFilters` struct type has been removed in v2. As a result, the `ArrayFilters` fields in the new `UpdateManyOptions` and `UpdateOneOptions` structs (which replace the old `UpdateOptions` struct) now use the `[]interface{}` type. The `ArrayFilters` field (now of type `[]interface{}`) serves the same purpose as the `Filters` field in the original `ArrayFilters` struct.

### Merge\*Options

All functions that merge options have been removed in favor of a generic solution. See [GODRIVER-2696](https://jira.mongodb.org/browse/GODRIVER-2696) for more information.
Expand Down
Loading