From d3670c2d3565038a449284bd4f5e89964d5a4b4c Mon Sep 17 00:00:00 2001 From: Dan Aprahamian Date: Fri, 12 Jul 2019 16:47:38 -0400 Subject: [PATCH] fix(autoEncryption): use new url parser for autoEncryption client Fixes NODE-2054 --- lib/operations/connect.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/operations/connect.js b/lib/operations/connect.js index fe600ff30ee..54b5c8a1cf9 100644 --- a/lib/operations/connect.js +++ b/lib/operations/connect.js @@ -493,7 +493,10 @@ function createTopology(mongoClient, topologyType, options, callback) { connectionString = 'mongodb://%2Ftmp%2Fmongocryptd.sock/?serverSelectionTimeoutMS=1000'; } - const mongocryptdClient = new MongoClient(connectionString, { useUnifiedTopology: true }); + const mongocryptdClient = new MongoClient(connectionString, { + useNewUrlParser: true, + useUnifiedTopology: true + }); mongocryptdClient.connect(err => { if (err) return callback(err, null);