Comparing version 6.10.0-dev.20241022.sha.678e9322 to 6.10.0-dev.20241024.sha.5c4355ad
@@ -7,3 +7,5 @@ "use strict"; | ||
const providers_1 = require("./providers"); | ||
// https://github.com/mongodb/specifications/blob/master/source/auth/auth.rst | ||
/** | ||
* @see https://github.com/mongodb/specifications/blob/master/source/auth/auth.md | ||
*/ | ||
function getDefaultAuthMechanism(hello) { | ||
@@ -10,0 +12,0 @@ if (hello) { |
@@ -72,3 +72,3 @@ "use strict"; | ||
// throw because the serverNonce's leading 32 bytes must equal the client nonce's 32 bytes | ||
// https://github.com/mongodb/specifications/blob/875446db44aade414011731840831f38a6c668df/source/auth/auth.rst#id11 | ||
// https://github.com/mongodb/specifications/blob/master/source/auth/auth.md#conversation-5 | ||
// TODO(NODE-3483) | ||
@@ -75,0 +75,0 @@ throw new error_1.MongoRuntimeError('Server nonce does not begin with client nonce'); |
@@ -17,3 +17,3 @@ "use strict"; | ||
* The legacy error message from the server that indicates the node is not a writable primary | ||
* https://github.com/mongodb/specifications/blob/b07c26dc40d04ac20349f989db531c9845fdd755/source/server-discovery-and-monitoring/server-discovery-and-monitoring.rst#not-writable-primary-and-node-is-recovering | ||
* https://github.com/mongodb/specifications/blob/921232976f9913cf17415b5ef937ee772e45e6ae/source/server-discovery-and-monitoring/server-discovery-and-monitoring.md#not-writable-primary-and-node-is-recovering | ||
*/ | ||
@@ -24,3 +24,3 @@ exports.LEGACY_NOT_WRITABLE_PRIMARY_ERROR_MESSAGE = new RegExp('not master', 'i'); | ||
* The legacy error message from the server that indicates the node is not a primary or secondary | ||
* https://github.com/mongodb/specifications/blob/b07c26dc40d04ac20349f989db531c9845fdd755/source/server-discovery-and-monitoring/server-discovery-and-monitoring.rst#not-writable-primary-and-node-is-recovering | ||
* https://github.com/mongodb/specifications/blob/921232976f9913cf17415b5ef937ee772e45e6ae/source/server-discovery-and-monitoring/server-discovery-and-monitoring.md#not-writable-primary-and-node-is-recovering | ||
*/ | ||
@@ -31,3 +31,3 @@ exports.LEGACY_NOT_PRIMARY_OR_SECONDARY_ERROR_MESSAGE = new RegExp('not master or secondary', 'i'); | ||
* The error message from the server that indicates the node is recovering | ||
* https://github.com/mongodb/specifications/blob/b07c26dc40d04ac20349f989db531c9845fdd755/source/server-discovery-and-monitoring/server-discovery-and-monitoring.rst#not-writable-primary-and-node-is-recovering | ||
* https://github.com/mongodb/specifications/blob/921232976f9913cf17415b5ef937ee772e45e6ae/source/server-discovery-and-monitoring/server-discovery-and-monitoring.md#not-writable-primary-and-node-is-recovering | ||
*/ | ||
@@ -66,3 +66,3 @@ exports.NODE_IS_RECOVERING_ERROR_MESSAGE = new RegExp('node is recovering', 'i'); | ||
}); | ||
// From spec@https://github.com/mongodb/specifications/blob/f93d78191f3db2898a59013a7ed5650352ef6da8/source/change-streams/change-streams.rst#resumable-error | ||
// From spec https://github.com/mongodb/specifications/blob/921232976f9913cf17415b5ef937ee772e45e6ae/source/change-streams/change-streams.md#resumable-error | ||
exports.GET_MORE_RESUMABLE_CODES = new Set([ | ||
@@ -1162,3 +1162,3 @@ exports.MONGODB_ERROR_CODES.HostUnreachable, | ||
exports.MongoWriteConcernError = MongoWriteConcernError; | ||
// https://github.com/mongodb/specifications/blob/master/source/retryable-reads/retryable-reads.rst#retryable-error | ||
// https://github.com/mongodb/specifications/blob/master/source/retryable-reads/retryable-reads.md#retryable-error | ||
const RETRYABLE_READ_ERROR_CODES = new Set([ | ||
@@ -1179,3 +1179,3 @@ exports.MONGODB_ERROR_CODES.HostUnreachable, | ||
]); | ||
// see: https://github.com/mongodb/specifications/blob/master/source/retryable-writes/retryable-writes.rst#terms | ||
// see: https://github.com/mongodb/specifications/blob/master/source/retryable-writes/retryable-writes.md#terms | ||
const RETRYABLE_WRITE_ERROR_CODES = RETRYABLE_READ_ERROR_CODES; | ||
@@ -1283,3 +1283,3 @@ function needsRetryableWriteLabel(error, maxWireVersion, serverType) { | ||
* | ||
* @see https://github.com/mongodb/specifications/blob/master/source/server-discovery-and-monitoring/server-discovery-and-monitoring.rst#not-master-and-node-is-recovering | ||
* @see https://github.com/mongodb/specifications/blob/master/source/server-discovery-and-monitoring/server-discovery-and-monitoring.md#not-writable-primary-and-node-is-recovering | ||
*/ | ||
@@ -1286,0 +1286,0 @@ function isSDAMUnrecoverableError(error) { |
@@ -26,3 +26,3 @@ "use strict"; | ||
* @see ./test/spec/crud/v2/aggregate-out-readConcern.json | ||
* @see https://github.com/mongodb/specifications/blob/master/source/read-write-concern/read-write-concern.rst#unknown-levels-and-additional-options-for-string-based-readconcerns | ||
* @see https://github.com/mongodb/specifications/blob/master/source/read-write-concern/read-write-concern.md#unknown-levels-and-additional-options-for-string-based-readconcerns | ||
*/ | ||
@@ -29,0 +29,0 @@ this.level = exports.ReadConcernLevel[level] ?? level; |
@@ -97,4 +97,4 @@ "use strict"; | ||
/** | ||
* Determines if another `ServerDescription` is equal to this one per the rules defined | ||
* in the {@link https://github.com/mongodb/specifications/blob/master/source/server-discovery-and-monitoring/server-discovery-and-monitoring.rst#serverdescription|SDAM spec} | ||
* Determines if another `ServerDescription` is equal to this one per the rules defined in the SDAM specification. | ||
* @see https://github.com/mongodb/specifications/blob/master/source/server-discovery-and-monitoring/server-discovery-and-monitoring.md | ||
*/ | ||
@@ -101,0 +101,0 @@ equals(other) { |
@@ -57,4 +57,6 @@ "use strict"; | ||
* Reduces the passed in array of servers by the rules of the "Max Staleness" specification | ||
* found here: https://github.com/mongodb/specifications/blob/master/source/max-staleness/max-staleness.rst | ||
* found here: | ||
* | ||
* @see https://github.com/mongodb/specifications/blob/master/source/max-staleness/max-staleness.md | ||
* | ||
* @param readPreference - The read preference providing max staleness guidance | ||
@@ -154,4 +156,5 @@ * @param topologyDescription - The topology description | ||
* further specified in the "Server Selection" specification, found here: | ||
* https://github.com/mongodb/specifications/blob/master/source/server-selection/server-selection.rst | ||
* | ||
* @see https://github.com/mongodb/specifications/blob/master/source/server-selection/server-selection.md | ||
* | ||
* @param topologyDescription - The topology description | ||
@@ -158,0 +161,0 @@ * @param servers - The list of servers to reduce |
@@ -892,4 +892,7 @@ "use strict"; | ||
} | ||
// TODO(NODE-4936): read concern eligibility for commands should be codified in command construction | ||
// @see https://github.com/mongodb/specifications/blob/master/source/read-write-concern/read-write-concern.rst#read-concern | ||
/** | ||
* TODO(NODE-4936): read concern eligibility for commands should be codified in command construction | ||
* @internal | ||
* @see https://github.com/mongodb/specifications/blob/master/source/read-write-concern/read-write-concern.md#read-concern | ||
*/ | ||
function commandSupportsReadConcern(command) { | ||
@@ -896,0 +899,0 @@ if (command.aggregate || command.count || command.distinct || command.find || command.geoNear) { |
{ | ||
"name": "mongodb", | ||
"version": "6.10.0-dev.20241022.sha.678e9322", | ||
"version": "6.10.0-dev.20241024.sha.5c4355ad", | ||
"description": "The official MongoDB driver for Node.js", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
@@ -13,3 +13,5 @@ // Resolves the default auth mechanism according to | ||
// https://github.com/mongodb/specifications/blob/master/source/auth/auth.rst | ||
/** | ||
* @see https://github.com/mongodb/specifications/blob/master/source/auth/auth.md | ||
*/ | ||
function getDefaultAuthMechanism(hello: Document | null): AuthMechanism { | ||
@@ -16,0 +18,0 @@ if (hello) { |
@@ -110,3 +110,3 @@ import type { Binary, BSONSerializeOptions } from '../../bson'; | ||
// throw because the serverNonce's leading 32 bytes must equal the client nonce's 32 bytes | ||
// https://github.com/mongodb/specifications/blob/875446db44aade414011731840831f38a6c668df/source/auth/auth.rst#id11 | ||
// https://github.com/mongodb/specifications/blob/master/source/auth/auth.md#conversation-5 | ||
@@ -113,0 +113,0 @@ // TODO(NODE-3483) |
@@ -14,3 +14,3 @@ import * as os from 'os'; | ||
* @public | ||
* @see https://github.com/mongodb/specifications/blob/master/source/mongodb-handshake/handshake.rst#hello-command | ||
* @see https://github.com/mongodb/specifications/blob/master/source/mongodb-handshake/handshake.md#hello-command | ||
*/ | ||
@@ -17,0 +17,0 @@ export interface ClientMetadata { |
@@ -19,3 +19,3 @@ import type { Document } from './bson'; | ||
* The legacy error message from the server that indicates the node is not a writable primary | ||
* https://github.com/mongodb/specifications/blob/b07c26dc40d04ac20349f989db531c9845fdd755/source/server-discovery-and-monitoring/server-discovery-and-monitoring.rst#not-writable-primary-and-node-is-recovering | ||
* https://github.com/mongodb/specifications/blob/921232976f9913cf17415b5ef937ee772e45e6ae/source/server-discovery-and-monitoring/server-discovery-and-monitoring.md#not-writable-primary-and-node-is-recovering | ||
*/ | ||
@@ -27,3 +27,3 @@ export const LEGACY_NOT_WRITABLE_PRIMARY_ERROR_MESSAGE = new RegExp('not master', 'i'); | ||
* The legacy error message from the server that indicates the node is not a primary or secondary | ||
* https://github.com/mongodb/specifications/blob/b07c26dc40d04ac20349f989db531c9845fdd755/source/server-discovery-and-monitoring/server-discovery-and-monitoring.rst#not-writable-primary-and-node-is-recovering | ||
* https://github.com/mongodb/specifications/blob/921232976f9913cf17415b5ef937ee772e45e6ae/source/server-discovery-and-monitoring/server-discovery-and-monitoring.md#not-writable-primary-and-node-is-recovering | ||
*/ | ||
@@ -38,3 +38,3 @@ export const LEGACY_NOT_PRIMARY_OR_SECONDARY_ERROR_MESSAGE = new RegExp( | ||
* The error message from the server that indicates the node is recovering | ||
* https://github.com/mongodb/specifications/blob/b07c26dc40d04ac20349f989db531c9845fdd755/source/server-discovery-and-monitoring/server-discovery-and-monitoring.rst#not-writable-primary-and-node-is-recovering | ||
* https://github.com/mongodb/specifications/blob/921232976f9913cf17415b5ef937ee772e45e6ae/source/server-discovery-and-monitoring/server-discovery-and-monitoring.md#not-writable-primary-and-node-is-recovering | ||
*/ | ||
@@ -75,3 +75,3 @@ export const NODE_IS_RECOVERING_ERROR_MESSAGE = new RegExp('node is recovering', 'i'); | ||
// From spec@https://github.com/mongodb/specifications/blob/f93d78191f3db2898a59013a7ed5650352ef6da8/source/change-streams/change-streams.rst#resumable-error | ||
// From spec https://github.com/mongodb/specifications/blob/921232976f9913cf17415b5ef937ee772e45e6ae/source/change-streams/change-streams.md#resumable-error | ||
export const GET_MORE_RESUMABLE_CODES = new Set<number>([ | ||
@@ -1310,3 +1310,3 @@ MONGODB_ERROR_CODES.HostUnreachable, | ||
// https://github.com/mongodb/specifications/blob/master/source/retryable-reads/retryable-reads.rst#retryable-error | ||
// https://github.com/mongodb/specifications/blob/master/source/retryable-reads/retryable-reads.md#retryable-error | ||
const RETRYABLE_READ_ERROR_CODES = new Set<number>([ | ||
@@ -1328,3 +1328,3 @@ MONGODB_ERROR_CODES.HostUnreachable, | ||
// see: https://github.com/mongodb/specifications/blob/master/source/retryable-writes/retryable-writes.rst#terms | ||
// see: https://github.com/mongodb/specifications/blob/master/source/retryable-writes/retryable-writes.md#terms | ||
const RETRYABLE_WRITE_ERROR_CODES = RETRYABLE_READ_ERROR_CODES; | ||
@@ -1466,3 +1466,3 @@ | ||
* | ||
* @see https://github.com/mongodb/specifications/blob/master/source/server-discovery-and-monitoring/server-discovery-and-monitoring.rst#not-master-and-node-is-recovering | ||
* @see https://github.com/mongodb/specifications/blob/master/source/server-discovery-and-monitoring/server-discovery-and-monitoring.md#not-writable-primary-and-node-is-recovering | ||
*/ | ||
@@ -1469,0 +1469,0 @@ export function isSDAMUnrecoverableError(error: MongoError): boolean { |
@@ -254,3 +254,3 @@ import { promises as fs } from 'fs'; | ||
* Automatic encryption is an enterprise only feature that only applies to operations on a collection. Automatic encryption is not supported for operations on a database or view, and operations that are not bypassed will result in error | ||
* (see [libmongocrypt: Auto Encryption Allow-List](https://github.com/mongodb/specifications/blob/master/source/client-side-encryption/client-side-encryption.rst#libmongocrypt-auto-encryption-allow-list)). To bypass automatic encryption for all operations, set bypassAutoEncryption=true in AutoEncryptionOpts. | ||
* (see [libmongocrypt: Auto Encryption Allow-List](https://github.com/mongodb/specifications/blob/master/source/client-side-encryption/client-side-encryption.md#libmongocrypt-auto-encryption-allow-list)). To bypass automatic encryption for all operations, set bypassAutoEncryption=true in AutoEncryptionOpts. | ||
* | ||
@@ -257,0 +257,0 @@ * Automatic encryption requires the authenticated user to have the [listCollections privilege action](https://www.mongodb.com/docs/manual/reference/command/listCollections/#dbcmd.listCollections). |
@@ -34,3 +34,3 @@ import type { Document } from './bson'; | ||
* @see ./test/spec/crud/v2/aggregate-out-readConcern.json | ||
* @see https://github.com/mongodb/specifications/blob/master/source/read-write-concern/read-write-concern.rst#unknown-levels-and-additional-options-for-string-based-readconcerns | ||
* @see https://github.com/mongodb/specifications/blob/master/source/read-write-concern/read-write-concern.md#unknown-levels-and-additional-options-for-string-based-readconcerns | ||
*/ | ||
@@ -37,0 +37,0 @@ this.level = ReadConcernLevel[level] ?? level; |
@@ -162,4 +162,4 @@ import { type Document, Long, type ObjectId } from '../bson'; | ||
/** | ||
* Determines if another `ServerDescription` is equal to this one per the rules defined | ||
* in the {@link https://github.com/mongodb/specifications/blob/master/source/server-discovery-and-monitoring/server-discovery-and-monitoring.rst#serverdescription|SDAM spec} | ||
* Determines if another `ServerDescription` is equal to this one per the rules defined in the SDAM specification. | ||
* @see https://github.com/mongodb/specifications/blob/master/source/server-discovery-and-monitoring/server-discovery-and-monitoring.md | ||
*/ | ||
@@ -166,0 +166,0 @@ equals(other?: ServerDescription | null): boolean { |
@@ -78,4 +78,6 @@ import { MongoCompatibilityError, MongoInvalidArgumentError } from '../error'; | ||
* Reduces the passed in array of servers by the rules of the "Max Staleness" specification | ||
* found here: https://github.com/mongodb/specifications/blob/master/source/max-staleness/max-staleness.rst | ||
* found here: | ||
* | ||
* @see https://github.com/mongodb/specifications/blob/master/source/max-staleness/max-staleness.md | ||
* | ||
* @param readPreference - The read preference providing max staleness guidance | ||
@@ -216,4 +218,5 @@ * @param topologyDescription - The topology description | ||
* further specified in the "Server Selection" specification, found here: | ||
* https://github.com/mongodb/specifications/blob/master/source/server-selection/server-selection.rst | ||
* | ||
* @see https://github.com/mongodb/specifications/blob/master/source/server-selection/server-selection.md | ||
* | ||
* @param topologyDescription - The topology description | ||
@@ -220,0 +223,0 @@ * @param servers - The list of servers to reduce |
@@ -1100,4 +1100,7 @@ import * as crypto from 'crypto'; | ||
// TODO(NODE-4936): read concern eligibility for commands should be codified in command construction | ||
// @see https://github.com/mongodb/specifications/blob/master/source/read-write-concern/read-write-concern.rst#read-concern | ||
/** | ||
* TODO(NODE-4936): read concern eligibility for commands should be codified in command construction | ||
* @internal | ||
* @see https://github.com/mongodb/specifications/blob/master/source/read-write-concern/read-write-concern.md#read-concern | ||
*/ | ||
export function commandSupportsReadConcern(command: Document): boolean { | ||
@@ -1104,0 +1107,0 @@ if (command.aggregate || command.count || command.distinct || command.find || command.geoNear) { |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
73773
3527247