Skip to content

Commit

Permalink
GODRIVER-2997 Prevent cancelable context in txn commit loop
Browse files Browse the repository at this point in the history
  • Loading branch information
prestonvasquez committed Oct 6, 2023
1 parent 92aa76c commit bf1b728
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion mongo/session.go
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ func (s *sessionImpl) WithTransaction(ctx context.Context, fn func(ctx SessionCo

CommitLoop:
for {
err = s.CommitTransaction(ctx)
err = s.CommitTransaction(newBackgroundContext(ctx))
// End when error is nil, as transaction has been committed.
if err == nil {
return res, nil
Expand Down

0 comments on commit bf1b728

Please sign in to comment.