File tree Expand file tree Collapse file tree 1 file changed +12
-4
lines changed
src/mongocxx/include/mongocxx/v_noabi/mongocxx Expand file tree Collapse file tree 1 file changed +12
-4
lines changed Original file line number Diff line number Diff line change @@ -185,10 +185,18 @@ class client_session {
185
185
// / the transaction, the entire sequence may be retried, and the callback
186
186
// / may be run multiple times.
187
187
// /
188
- // / If the user callback calls driver methods that run operations against the
189
- // / server that can throw an operation_exception (ex: collection::insert_one),
190
- // / the user callback should allow those exceptions to propagate up the stack
191
- // / so they can be caught and processed by the with_transaction helper.
188
+ // / This method has an internal non-adjustable time limit of 120 seconds,
189
+ // / including all retries.
190
+ // /
191
+ // / If the user callback invokes driver methods that run operations against the
192
+ // / server which could throw an operation_exception, the user callback MUST allow
193
+ // / those exceptions to propagate up the stack so they can be caught and processed
194
+ // / by the with_transaction() helper.
195
+ // /
196
+ // / For example, a callback that invokes collection::insert_one may encounter a
197
+ // / "duplicate key" error with accompanying server-side transaction abort. If this
198
+ // / error were not seen by the with_transaction() helper, the entire transaction
199
+ // / would retry repeatedly until the overall time limit expires.
192
200
// /
193
201
// / @param cb
194
202
// / The callback to run inside of a transaction.
You can’t perform that action at this time.
0 commit comments