@@ -26,6 +26,7 @@ and deprecations made in each version of the driver libraries.
2626
2727Learn what's new in:
2828
29+ * :ref:`Version 2.0.0 <c-version-2.0.0>`
2930* :ref:`Version 1.30.0 <c-version-1.30.0>`
3031* :ref:`Version 1.29.0 <c-version-1.29.0>`
3132* :ref:`Version 1.28.0 <c-version-1.28.0>`
@@ -42,6 +43,145 @@ Learn what's new in:
4243
4344.. _c-upcoming-breaking-changes:
4445
46+ .. _c-version-2.0.0:
47+
48+ What's New in 2.0.0
49+ --------------------
50+
51+ The following sections describe the changes in the 2.0.0 release of
52+ the {+driver-short+}.
53+
54+ .. important:: Removals
55+
56+ The 2.0.0 driver release removes many deprecated types and methods. To view
57+ a full list of removals, see the **Removals** sections of the
58+ :github:`v2.0 release notes </mongodb/mongo-c-driver/releases/tag/2.0.0>`.
59+
60+ {+libbson+}
61+ ~~~~~~~
62+
63+ The 2.0.0 release of ``{+libbson+}`` includes the following changes:
64+
65+ New Features
66+ ````````````
67+
68+ - Adds support for the BSON Binary Vector subtype. To learn more, see
69+ `BSON Binary Vector subtype <{+api-libbson+}/binary_vector.html>`__ in
70+ the {+libbson+} API documentation.
71+
72+ Changes
73+ ```````
74+
75+ - Reduces the value of the ``BSON_ERROR_BUFFER_SIZE`` macro from ``504``
76+ to ``503`` to reserve the final byte for internal use.
77+
78+ - Renames the following ``pkg-config`` files:
79+
80+ - ``libbson-1.0``: Renamed to ``bson2``
81+ - ``libbson-static-1.0``: Renamed to ``bson2-static``
82+
83+ - Removes the ``bson-1.0`` CMake package. Instead, use ``bson`` and
84+ specify a version or version range to be imported, as shown in the
85+ following example:
86+
87+ .. code-block:: c
88+
89+ find_package(bson 1.30...2.0)
90+
91+ - Renames the following imported targets:
92+
93+ - ``mongo::bson_static``: Renamed to ``bson::static``
94+ - ``mongo::bson_shared``: Renamed to ``bson::shared``
95+
96+ - Adds the ``bson::bson`` target, which points to either the static
97+ library or shared library depending on the value of the
98+ ``BSON_DEFAULT_IMPORTED_LIBRARY_TYPE`` CMake option. If you don't set this option and
99+ both library types are available, ``bson::bson`` uses
100+ the static library.
101+
102+ {+libmongoc+}
103+ ~~~~~~~~~
104+
105+ The 2.0.0 release of ``{+libmongoc+}`` includes the following changes:
106+
107+ New Features
108+ ````````````
109+
110+ - Supports aggregate operations that include ``$lookup`` stages for
111+ In-Use Encryption. To learn more, see the following
112+ references in the {+mdb-server+} manual:
113+
114+ - :upcoming:`$lookup and $graphLookup Behavior </core/csfle/reference/supported-operations/#-lookup-and--graphlookup-behavior>` for CSFLE
115+ - :upcoming:`$lookup and $graphLookup Behavior </core/queryable-encryption/reference/supported-operations/#-lookup-and--graphlookup-behavior>` for QE
116+
117+ Changes
118+ ```````
119+
120+ - If you pass the ``batchSize:0`` option to ``mongoc_client_watch``, ``mongoc_database_watch``,
121+ or ``mongoc_collection_watch``, the ``aggregate`` command no longer ignores this option and
122+ applies it.
123+
124+ - Removes ``bson_oid_init_sequence``. Instead, use ``bson_oid_init``.
125+
126+ - Changes the return type of ``mongoc_server_description_host`` from ``mongoc_host_list_t *``
127+ to ``const mongoc_host_list_t *``.
128+
129+ - Implements the following changes to URI authentication credentials validation, which
130+ apply when creating a new ``mongoc_uri_t`` object from a connection string:
131+
132+ - Requires that usernames are non-empty for all authentication mechanisms.
133+ - Validates username and password specification requirements and returns
134+ a client error for the specified authentication mechanism.
135+ - For the ``MONGODB-AWS`` authentication mechanism, the ``authSource`` value defaults to
136+ ``$external``.
137+ - Validates ``authMechanism`` values and returns a client error for invalid values.
138+ - Validates ``authMechanismProperties`` values and returns a client error for invalid
139+ properties for the specified authentication mechanism.
140+ - Correctly parses colon (``:``) characters within ``authMechanismProperties`` values.
141+ For example, setting ``authMechanismProperties=A:B,C:D:E,F:G`` caused the driver to
142+ parse the value as ``{'A': 'B', 'C': 'D:E,F:G'}``. This is now parsed as
143+ ``{'A': 'B': 'C': 'D:E', 'F': 'G'}``.
144+
145+ - Generates an error if you call ``mongoc_bulk_operation_execute`` on the same
146+ ``mongoc_bulk_operation_t`` repeatedly.
147+
148+ - Consistently applies the ``__cdecl`` calling convention to function declarations in
149+ the public API.
150+
151+ - ``mongoc_client_set_ssl_opts`` ignores a pooled ``mongoc_client_t`` and logs an error.
152+ Before popping a client, use ``mongoc_client_pool_set_ssl_opts`` to set TLS options on
153+ a ``mongoc_client_pool_t``.
154+
155+ - ``mongoc_client_set_ssl_stream_initiator`` ignores a pooled ``mongoc_client_t`` and
156+ logs an error.
157+
158+ - Renames the following ``pkg-config`` files:
159+
160+ - ``libmongoc-1.0``: Renamed to ``mongoc2``
161+ - ``libmongoc-static-1.0``: Renamed to ``mongoc2-static``
162+
163+ - Removes the ``mongoc-1.0`` CMake package. Instead, use ``mongoc`` and
164+ specify a version or version range to be imported, as shown in the
165+ following example:
166+
167+ .. code-block:: c
168+
169+ find_package(mongoc 1.30...2.0)
170+
171+ - Renames the following imported targets:
172+
173+ - ``mongo::mongoc_static``: Renamed to ``mongoc::static``
174+ - ``mongo::mongoc_shared``: Renamed to ``mongoc::shared``
175+
176+ - Adds the ``mongoc::mongoc`` target, which points to either the static
177+ library or shared library depending on the value of the
178+ ``MONGOC_DEFAULT_IMPORTED_LIBRARY_TYPE`` CMake option. If you don't set this option and
179+ both library types are available, ``mongoc::mongoc`` uses
180+ the static library.
181+
182+ For more information about this release, see the :github:`v2.0 release notes
183+ </mongodb/mongo-c-driver/releases/tag/2.0.0>`.
184+
45185.. _c-version-1.30.0:
46186
47187What's New in 1.30.0
@@ -532,4 +672,4 @@ New Features
532672Improvements
533673````````````
534674- Adds ``VERSION_CURRENT`` file in source to ease building
535- - Considers more errors retryable
675+ - Considers more errors retryable
0 commit comments