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
Copy file name to clipboardExpand all lines: src/sessions.ts
+5-3Lines changed: 5 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -448,15 +448,17 @@ export class ClientSession extends TypedEventEmitter<ClientSessionEvents> {
448
448
*
449
449
* **IMPORTANT:** This method requires the function passed in to return a Promise. That promise must be made by `await`-ing all operations in such a way that rejections are propagated to the returned promise.
450
450
*
451
+
* **IMPORTANT:** Running operations in parallel is not supported during a transaction. The use of `Promise.all`,
452
+
* `Promise.allSettled`, `Promise.race`, etc to parallelize operations inside a transaction is
453
+
* undefined behaviour.
454
+
*
455
+
*
451
456
* @remarks
452
457
* - If all operations successfully complete and the `commitTransaction` operation is successful, then the provided function will return the result of the provided function.
453
458
* - If the transaction is unable to complete or an error is thrown from within the provided function, then the provided function will throw an error.
454
459
* - If the transaction is manually aborted within the provided function it will not throw.
455
460
* - If the driver needs to attempt to retry the operations, the provided function may be called multiple times.
456
461
*
457
-
* **IMPORTANT:** Running operations in parallel is not supported during a transaction. The use of `Promise.all`,
458
-
* `Promise.allSettled`, `Promise.race`, etc to parallelize operations inside a transaction is
0 commit comments