@@ -17,9 +17,9 @@ What's New
1717.. meta::
1818 :keywords: version, update, upgrade, backwards compatibility
1919
20-
2120Learn what's new in:
2221
22+ * :ref:`Version 6.6 <version-6.6>`
2323* :ref:`Version 6.5 <version-6.5>`
2424* :ref:`Version 6.4 <version-6.4>`
2525* :ref:`Version 6.3 <version-6.3>`
@@ -57,6 +57,91 @@ Learn what's new in:
5757* :ref:`Version 3.7 <version-3.7>`
5858* :ref:`Version 3.6 <version-3.6>`
5959
60+ .. _version-6.6:
61+
62+ What's New in 6.6
63+ -----------------
64+
65+ The {+driver-short+} v6.6 release includes the following features:
66+
67+ - Upgrades to using BSON 6.7.0. For details about the new BSON features, see the
68+ release notes for `BSON 6.5.0
69+ <https://github.com/mongodb/js-bson/releases/tag/v6.5.0>`__,
70+ `BSON 6.6.0 <https://github.com/mongodb/js-bson/releases/tag/v6.6.0>`__, and
71+ `BSON 6.7.0 <https://github.com/mongodb/js-bson/releases/tag/v6.7.0>`__.
72+
73+ - Adds the ``addStage()`` method to the fluid aggregation API. You can use this method to
74+ add aggregation pipeline stages individually, as shown in the following
75+ example:
76+
77+ .. code-block:: javascript
78+
79+ const documents = await users.aggregate().addStage({ $project: { name: true } }).toArray();
80+
81+ - Adds the ``cause`` and ``dependencyName`` fields to the ``MongoMissingDependencyError``
82+ class. You can use these fields to programmatically determine if a package is missing
83+ or why a package didn't load.
84+
85+ - Adds the ``minRoundTripTime`` property to the ``ServerDescription`` class. This
86+ property contains the minimum round-trip time over the last 10 heartbeats.
87+
88+ - Adds the ``toJSON()`` method to the ``TopologyDescription`` class. Although you can use
89+ this method to stringify ``TopologyDescription`` objects to JSON, we
90+ recommend using Node's ``util.inspect()`` method instead, because it properly handles
91+ all types used in JavaScript and the driver.
92+
93+ - Adds cursor options support for the ``Collection.indexExists()``,
94+ ``Collection.indexes()``, and ``Collection.indexInformation()`` methods in Typescript.
95+
96+ - Removes support for the ``readConcern`` and ``writeConcern`` options from the
97+ ``Collection.listSearchIndexes()`` method. ``listSearchIndexes()`` is an Atlas-specific method, and Atlas
98+ search indexes don't support these options.
99+
100+ - Redefines the ``ServerDescription.roundTripTime`` property as a moving average. Previously,
101+ it was a weighted average of the most recently observed heartbeat duration and the
102+ previous duration.
103+
104+ - You can specify the type of a search index when creating the index, as shown
105+ in the following example:
106+
107+ .. code-block:: js
108+ :emphasize-lines: 3
109+
110+ const indexName = await collection.createSearchIndex({
111+ name: 'my-vector-search-index',
112+ type: 'vectorSearch',
113+ definition: {
114+ mappings: { dynamic: false }
115+ }
116+ });
117+
118+ - The ``UpdateFilter.$currentDate`` property no longer throws an error when you pass
119+ it to a compound method, such as ``findOneAndUpdate()``, on a collection with a limited schema.
120+
121+ - The driver throws a ``MongoTransactionError`` only if you provide a
122+ ``ReadPreferenceMode`` other than ``primary`` and then try to perform a command that
123+ involves a read operation.
124+
125+ - The data type of the ``TopologyDescription.error`` property is ``MongoError``.
126+
127+ - The ``Collection.indexExists()`` method no longer supports the ``full`` option.
128+
129+ - The ``Collection.indexInformation()``, ``Collection.indexes()``, and
130+ ``Db.indexInformation()`` methods have a return type of
131+ ``IndexDescriptionCompact | IndexDescriptionInfo[]`` in TypeScript.
132+
133+ - When retrieving AWS KMS (Key Management System) credentials, the driver no longer
134+ throws an error when it receives an access key that includes
135+ an expiration timestamp.
136+
137+ - The ``ClusterTime`` interface no longer defines the ``signature`` field as required in
138+ TypeScript.
139+
140+ To learn more about this release, see the
141+ `v6.6.0 Release Highlights
142+ <https://github.com/mongodb/node-mongodb-native/releases/tag/v6.6.0>`__ on
143+ GitHub.
144+
60145.. _version-6.5:
61146
62147What's New in 6.5
0 commit comments