Update module go.mongodb.org/mongo-driver to v1.12.0 #13
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
v1.11.7
->v1.12.0
Release Notes
mongodb/mongo-go-driver (go.mongodb.org/mongo-driver)
v1.12.0
: MongoDB Go Driver 1.12.0Compare Source
The MongoDB Go Driver Team is pleased to release version 1.12.0 of the official Go driver.
Release Notes
This release adds support for MongoDB 7.0, including production-ready support for Queryable Encryption. It also adds a new logging interface and configuration API improvements.
Production-Ready Queryable Encryption
This release introduces backwards breaking changes to the Queryable Encryption protocol. Using Queryable Encryption now requires MongoDB 7.0+ and libmongocrypt v1.8.0+.
It also adds the new
ClientEncryption.CreateEncryptedCollection
method to automatically create data encryption keys when creating a new encrypted collection and adds the ability to fetch KMS credentials automatically from Azure, GCP, and AWS environments.Logging
This release introduces a logging interface to allow users to more easily record detailed information about connection management and command execution within their application.
The logging configuration adds a new
LogSink
interface that is compatible with the logr.LogSink interface, allowing users to use existinglogr
adapters, like zerologr or zapr. Users may also implement their ownLogSink
adapter.For example, to integrate logging with an existing zerolog logger:
Logging can also be enabled using environment variables. For example, to enable command logging at info level to
client.log
, set:Convenient BSON Options
The
options
package has a new way to set various BSON marshaling and unmarshaling behaviors.For example, to set BSON options that cause the Go driver to fallback to "json" struct tags if "bson" struct tags are missing, marshal
nil
Go maps as empty BSON documents, and marshalsnil
Go slices as empty BSON arrays, use the newoptions.BSONOptions
configuration:Convenient Write Concerns
The
writeconcern
package has new convenience functionsMajority
,W1
,Journaled
, andUnacknowledged
for creating common write concerns.For example, to configure a
Client
to use write concern {w: 1}, use the newwriteconcern.W1()
function:Additional Changes
SetBatchSize
toCursor
to allow specifying the size of batches fetched from the database when iterating a cursor. It is primarily intended for use with cursors returned by RunCommandCursor.bson.UnmarshalValue
to allow unmarshaling BSON values that were marshaled using the existing bson.MarshalValue.For a full list of tickets included in this release, please see the links below:
New Features
Improvements
Bugs
Tasks
Full Changelog: v1.11.7...1.12.0
Documentation for the Go driver can be found on pkg.go.dev and the MongoDB documentation site. BSON library documentation is also available on pkg.go.dev. Questions and inquiries can be asked on the MongoDB Developer Community. Bugs can be reported in the Go Driver project in the MongoDB JIRA where a list of current issues can be found. Your feedback on the Go driver is greatly appreciated!
Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR has been generated by Mend Renovate. View repository job log here.