diff --git a/types/mongodb/index.d.ts b/types/mongodb/index.d.ts index 19cf0136e2..32bc523d38 100644 --- a/types/mongodb/index.d.ts +++ b/types/mongodb/index.d.ts @@ -5,6 +5,7 @@ // Gady Piazza // Jason Dreyzehner // Gaurav Lahoti +// Mariano Cortesi // Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped // TypeScript Version: 2.3 @@ -146,6 +147,9 @@ export interface DbCreateOptions { promiseLibrary?: Object; // https://docs.mongodb.com/manual/reference/read-concern/#read-concern readConcern?: { level?: Object }; + // Sets a cap on how many operations the driver will buffer up before giving up on getting a + // working connection, default is -1 which is unlimited. + bufferMaxEntries?: number; } // http://mongodb.github.io/node-mongodb-native/2.2/api/Server.html diff --git a/types/mongodb/mongodb-tests.ts b/types/mongodb/mongodb-tests.ts index 2b8c49d186..52f2d6e4f8 100644 --- a/types/mongodb/mongodb-tests.ts +++ b/types/mongodb/mongodb-tests.ts @@ -3,7 +3,7 @@ import mongodb = require('mongodb'); var MongoClient = mongodb.MongoClient; var format = require('util').format; -let options = { +let options: mongodb.MongoClientOptions = { authSource : ' ', w : 1, wtimeout : 300,