Docs Menu
Docs Home
/ / /
Ruby Driver
/

Release Notes

Learn what's new in:

  • Version 2.21.1

  • Version 2.21

  • Version 2.20

The Ruby driver 2.21.1 release includes the following new features, changes, and improvements:

  • Adds the type parameter to the Mongo::SearchIndex::View#create_one and Mongo::SearchIndex::View#create_many Search index creation methods. This enables you to create Atlas Vector Search indexes programmatically. To learn more and view examples, see the Atlas Search Indexes guide.

  • Adds compatibility with Ruby 3.3. To learn more, see Compatibility.

The bson gem is the implementation of the BSON specification in Ruby. bson v5.1 accompanies the Ruby driver v2.21.1 release.

The bson 5.1 release includes the following new features, changes, and improvements:

  • Adds the BSON::Vector type to represent vectors of numeric values. To learn more, see the BSON::Vector section of the BSON guide.

  • BSON::Document objects do not support use of the #deep_symbolize_keys! and #symbolize_keys! methods. In previous versions, the #symbolize_keys! method raises an ArgumentError when used on a BSON::Document, but #deep_symbolize_keys! does not, and only returns a Hash rather than a BSON::Document.

    This release adds a warning when you use #deep_symbolize_keys! on a BSON::Document instance. In bson v6.0, this action will raise an error.

The Ruby driver 2.21 release includes the following new features:

  • Supports the Client-Side Operations Timeout (CSOT) feature, which unifies most timeout-related options under a single timeout_ms option.

  • Supports MongoDB Server version 8.0.

  • Support for range v2 queries with Queryable Encryption, including a new trim_factor parameter. For more information about Queryable Encryption, see Queryable Encryption in the MongoDB Server manual.

To learn more about this release, see the v2.21 Release Notes on GitHub.

The Ruby driver 2.20 release includes the following new features:

  • Discontinues support for Ruby 2.5 and 2.6. Deprecates support for Ruby 2.7 and JRuby 9.2, which will be discontinued in the next minor driver version. Adds support for JRuby 9.4.

  • Supports the newly-released Ruby-BSON version 5.0.

  • Allows connection strings without a slash between the hosts and the options. For example, mongodb://example.com?w=1 and mongodb://example.com/?w=1 are both valid connection strings now.

  • Sends container runtime and orchestration metadata for the client environment to the server for analytics purposes.

  • Writes a warning message to the log when detecting the host as a CosmosDB (Azure) or DocumentDB (Amazon) instance.

  • Attempts retries of read or write operations on a different mongos instance in a sharded topology, if possible.

To learn more about this release, see the v2.20 Release Notes on GitHub.

Back

Reference

On this page