You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: source/whats-new.txt
+37-21Lines changed: 37 additions & 21 deletions
Original file line number
Diff line number
Diff line change
@@ -113,19 +113,35 @@ To learn more, see the `v4.12.0 Release Highlights <https://github.com/mongodb/n
113
113
What's New in 4.11
114
114
------------------
115
115
116
+
Prioritization Order in Monitoring
117
+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
118
+
116
119
When connecting to MongoDB Server version 6.0 or later, the driver prioritizes
117
120
``electionId`` settings before ``setVersion`` settings during Server Discovery and
118
121
Monitoring events. In previous versions, the prioritization order was reversed.
119
122
120
-
This release also includes added support for **mutually
123
+
Changes to AWS Authentication
124
+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
125
+
126
+
When you install the optional ``aws-sdk/credential-providers``
127
+
dependency, the driver uses the AWS SDK to retrieve AWS credentials from the
128
+
environment.
129
+
130
+
To learn more about this behavior, see the :ref:`MONGODB-AWS
131
+
<mongodb-aws>` section of the Authentication Mechanisms guide.
132
+
133
+
Mutually Recursive Schema Type Checking
134
+
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
135
+
136
+
This release includes added support for **mutually
121
137
recursive** collection schema types. The driver also provides type safety for
122
138
dot-notation queries up to a depth of eight in this release. At a depth greater
123
139
than or equal to eight, Typescript successfully compiles your code but does not
124
140
provide type safety. This depth limit on recursive types is a current limitation
125
141
of TypeScript.
126
142
127
-
Mutually Recursive Schema Type Checking Example
128
-
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
143
+
Example
144
+
```````
129
145
130
146
Suppose we have a collection of type ``Collection<Author>`` that contains the
131
147
following mutually recursive types:
@@ -363,7 +379,7 @@ Key Changes
363
379
~~~~~~~~~~~
364
380
365
381
Node.js Version
366
-
+++++++++++++++
382
+
```````````````
367
383
368
384
The minimum supported version of Node.js is now v12.9 or greater for
369
385
version 4 of the driver. Support for our 3.x branches will continue
@@ -375,7 +391,7 @@ until summer 2022 to allow time to upgrade.
375
391
376
392
377
393
Cursor Improvements
378
-
+++++++++++++++++++
394
+
```````````````````
379
395
380
396
Our Cursor implementation is now updated to make it clear what is possible
381
397
before and after execution of an operation.
@@ -407,7 +423,7 @@ similar to the following:
407
423
- ``ListCollectionsCursor``
408
424
409
425
Cursor Stream API
410
-
^^^^^^^^^^^^^^^^^
426
+
+++++++++++++++++
411
427
412
428
Our Cursor types no longer extend ``Readable`` directly. They must be
413
429
transformed into a stream by calling ``cursor.stream()``.
@@ -427,7 +443,7 @@ Use ``for await of`` syntax or any ``Promise`` helpers for
427
443
asynchronous iteration.
428
444
429
445
``MongoClientOptions`` Interface
430
-
+++++++++++++++++++++++++++++++++
446
+
````````````````````````````````
431
447
432
448
With type hinting, you should find that options passed to a ``MongoClient``
433
449
are enumerated and discoverable. We've made a large effort to process
@@ -442,7 +458,7 @@ to get your app up and running in a correct state quickly.
442
458
- It is no longer required to specify ``useUnifiedTopology`` or ``useNewUrlParser``.
443
459
444
460
``createCollection()``
445
-
++++++++++++++++++++++
461
+
``````````````````````
446
462
447
463
This method no longer supports a ``strict`` option, which returned
448
464
an error if the collection did not exist. To assert the existence of
@@ -461,7 +477,7 @@ a collection, use the ``listCollections()`` method instead.
461
477
}
462
478
463
479
``BulkWriteError`` → ``MongoBulkWriteError``
464
-
++++++++++++++++++++++++++++++++++++++++++++
480
+
````````````````````````````````````````````
465
481
466
482
``BulkWriteError`` is now renamed to ``MongoBulkWriteError``.
467
483
@@ -470,20 +486,20 @@ depending on your settings. Import the new class name ``MongoBulkWriteError``
470
486
when testing for errors in bulk operations.
471
487
472
488
``DB``
473
-
++++++
489
+
``````
474
490
475
491
``DB`` is no longer an ``EventEmitter``. Listen for events directly from your
476
492
``MongoClient`` instance.
477
493
478
494
``Collection.group()``
479
-
++++++++++++++++++++++
495
+
``````````````````````
480
496
481
497
The ``Collection.group()`` helper, deprecated since MongoDB 3.4,
482
498
is now removed. Use the aggregation pipeline :manual:`$group </reference/operator/aggregation/group/#pipe._S_group>`
483
499
operator instead.
484
500
485
501
Authentication
486
-
++++++++++++++
502
+
``````````````
487
503
488
504
- ``gssapiServiceName`` is now removed. Use `authMechanismProperties.SERVICE_NAME <{+api+}/interfaces/MongoClientOptions.html#authMechanismProperties>`__ in the URI or as an option on ``MongoClientOptions``.
0 commit comments