# MongoDB Node.js Driver v6.19.0 - Product: MongoDB Node.js Driver (https://whatsnew.fyi/product/mongodb-node-driver) - Vendor: MongoDB - Date: 2025-08-26 - Version: v6.19.0 - Original notes: https://github.com/mongodb/node-mongodb-native/releases/tag/v6.19.0 - Permalink: https://whatsnew.fyi/product/mongodb-node-driver/releases/v6.19.0 What's New is an index, not a publisher: every entry below links to the vendor's own release notes, which are the authoritative source. Entries are labelled where they are hand-curated sample data, pre-releases, or drawn from a secondary source such as a developer blog. Reuse: the summaries, labels and curation here are © What's New. Quote freely with attribution and a link back; wholesale republication of the corpus is not permitted — terms: https://whatsnew.fyi/terms. The vendors' own release notes remain their publishers'. --- - **added** — Support queryable encryption text field prefix, suffix and substring queries - **added** — Allow secureContext option in KMS TLS options for auto encryption and client encryption - **changed** — findOne command now always sets limit to 1 and singleBatch to true - **changed** — find command sets limit to batchSize + 1 when both options are equal to avoid leaving cursors open - **deprecated** — limit, noCursorResponse and batchSize options in findOne and find commands - **changed** — MongoClient no longer sends ping command on connect when authentication is enabled, instead checks out a connection from the pool to force initial handshake ##### [6.19.0](https://github.com/mongodb/node-mongodb-native/compare/v6.18.0...v6.19.0) (2025-08-26) The MongoDB Node.js team is pleased to announce version 6.19.0 of the `mongodb` package! ##### Release Notes ###### Experimental Support for Queryable Encryption Text Field Prefix, Suffix and Substring Queries > [!IMPORTANT] > Substring, prefix and suffix search are in preview and should be used for experimental workloads only. These features are unstable and their security is not guaranteed until released as Generally Available (GA). The GA version of these features may not be backwards compatible with the preview version. When using Queryable Encryption with both automatic encryption and explicit encryption, text fields can now be queried using prefix, suffix and substring queries. This feature requires `mongodb-client-encryption@>=6.5.0`. ###### Allow a `secureContext` for Auto Encryption and Client Encryption TLS options This can be provided in the `tlsOptions` option both both objects. ```ts import * as tls from 'tls'; import { ClientEncryption, MongoClient } from 'mongodb'; const caFile = await fs.readFile(process.env.CSFLE_TLS_CA_FILE); const certFile = await fs.readFile(process.env.CSFLE_TLS_CLIENT_CERT_FILE); const secureContextOptions = { ca: caFile, key: certFile, cert: certFile }; const options = { keyVaultNamespace: 'db.coll', kmsProviders: { aws: {} } }, tlsOptions: { aws: { secureContext: tls.createSecureContext(secureContextOptions), } } }; const client = this.configuration.newClient({}, { autoEncryption: { ...options, schemaMap } }); const clientEncryption = new ClientEncryption(client, options); ``` ###### `collection.findOne()` and `collection.find()` will no longer potentially leave open cursors on the server The `findOne` command will now always set the `limit` option to `1` and `singleBatch` to `true`. The `limit`, `noCursorResponse` and `batchSize` options have also been deprecated, and the command will guarantee no more cursors can be orphaned and no `killCursors` command will be potentially executed. `find` will now set `limit` to `batchSize + 1` when both options were equal, to avoid leaving cursors open. ###### Clients no longer send a ping on connect When authentication is enabled, the `MongoClient` will no longer send a `ping` command when connecting since it is unnecessary. Instead it will check a connection out of the pool to force the initial handshake, and check it back in. ###### Features * **NODE-4179:** allow secureContext in KMS TLS options ([#4578](https://github.com/mongodb/node-mongodb-native/issues/4578)) ([0ea6eaa](https://github.com/mongodb/node-mongodb-native/commit/0ea6eaa82d56073f1a63d4168935d63a4a4e7a61)) * **NODE-6472:** findOne and find no longer keep open cursors ([#4580](https://github.com/mongodb/node-mongodb-native/issues/4580)) ([be7f808](https://github.com/mongodb/node-mongodb-native/commit/be7f808c3ff0d894906ec187de98e159ebb7b18d)) * **NODE-7020:** remove ping on connect ([#4607](https://github.com/mongodb/node-mongodb-native/issues/4607)) ([3d296b7](https://github.com/mongodb/node-mongodb-native/commit/3d296b7d94810c3bc29153ffc3c8795f02699dd4)) * **NODE-7059, NODE-7008:** add support for text queries for QE string fields ([#4597](https://github.com/mongodb/node-mongodb-native/issues/4597)) ([e4492f3](https://github.com/mongodb/node-mongodb-native/commit/e4492f3ff260a440ab4b2cb64ca90a68f9cf6fd5)) ##### Documentation * [Reference](https://docs.mongodb.com/drivers/node/current/) * [API](https://mongodb.github.io/node-mongodb-native/6.19/) * [Changelog](https://github.com/mongodb/node-mongodb-native/blob/v6.19.0/HISTORY.md) We invite you to try the `mongodb` library immediately, and report any issues to the [NODE project](https://jira.mongodb.org/projects/NODE).