The MongoDB Rust driver team is pleased to announce the v3.8.0 release of the mongodb crate, now available for download from crates.io.
Highlighted Changes
In-Use Encryption String API GA
The string API for in-use encryption (previously named the text API) is now stable and GA! This brings with it the following changes:
- The
text-indexes-unstablefeature is no longer required to enable this API. The feature still exists for backwards compatibility but does nothing. - The
TextOptionsstruct is nowStringOptions. Algorithm::TextPreviewis deprecated in favor ofAlgorithm::String.- The query types
"prefixPreview","suffixPreview", and"substringPreview"are deprecated in favor of"prefix","suffix", and"substring"respectively.
The GA API requires mongodb server version 9.0. The preview API can continue to be used with pre-9.0 server versions.
Server 4.2 EOL
As of this release, connecting to server version 4.2 is deprecated. Support for 4.2 will be removed in the 3.9.0 release.
MONGODB-AWS explicit authentication property deprecation
The use of explicit username, password, or the "AWS_SESSION_TOKEN" property with the MONGODB-AWS auth mechanism is deprecated, and will emit warnings when debug assertions are enabled. Support for these will be removed in version 4.0 of the driver.
Hickory performance on Windows
A long-standing bug in the hickory-resolver case when running on Windows caused performance degredation when using a mongodb+srv connection string. Happily, this bug is now fixed, so users who previously used our recommended workaround of a custom DNS configuration on Windows can now remove that workaround.
Full Release Notes
Impactful changes are listed below; for a complete list of changes see this GitHub query.
New Features
- RUST-2402 QE string API GA (#1727)
- RUST-2376 Optionally redact errors containing URI elements (#1708)
Improvements
- RUST-2388 Add AGENTS.md (#1706)
- RUST-2299 Remove warnings about hickory performance (#1712)
- RUST-2358 Update attribute name in OpenTelemetry Spec (#1713)
- RUST-2248 Add deprecation warnings for explicit MONGODB-AWS auth properties (#1716)
- RUST-2369 Add constructor methods for ReadPreference (#1732) (thanks @OnjoujiToki!)