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
// Previous version of this test was too strict: we were expecting that only one session be used for this scenario.
111
+
// That was possible at the time because the operations were simple enough and the server fast enough that the operations would complete serially.
112
+
//
113
+
// However, with a more complex operation bulkWrite (like `Array.from({ length: 100_000 }).map(() => ({ insertOne: { document: { a: 1 }}})),`),
114
+
// it's entirely possible and expected that bulkWrite would introduce a second session due to the time it takes to process all the inserts.
115
+
//
116
+
// The important bit of the test is that the number of sessions is less than the number of concurrent operations, so now instead of expecting exactly 1 session,
117
+
// we just expect less than operations.length - 1 sessions.
0 commit comments