[SERVER-40996] abortTransaction in cleanup_txns.js does not handle LockTimeout Created: 03/May/19  Updated: 29/Oct/23  Resolved: 07/May/19

Status: Closed
Project: Core Server
Component/s: Replication
Affects Version/s: None
Fix Version/s: 4.1.11

Type: Bug Priority: Major - P3
Reporter: Matthew Russotto Assignee: Matthew Russotto
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
Related
related to SERVER-40757 Fix snapshot_read_kill_operations.js ... Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Sprint: Repl 2019-05-20
Participants:
Linked BF Score: 21

 Description   

Under heavy load, it is possible for abortTransaction to fail while checking out the session. In this case, we will get a LockTimeout (marked transient). The transaction has been aborted, so we can simply ignore this error.

The same code also fails to handle different errors for different shards, which can also happen. We can use the "raw" field to make sure each error is an allowable one.



 Comments   
Comment by Githook User [ 13/May/19 ]

Author:

{'name': 'Esha Maharishi', 'username': 'EshaMaharishi', 'email': 'esha.maharishi@mongodb.com'}

Message: Revert "SERVER-40996 abortTransaction in cleanup_txns.js does not handle different errors from different shards"

This reverts commit ba844b4e81c3914b8a7017bd2a8c5ac4231c72ff.

SERVER-40757 Fix snapshot_read_kill_operations.js to handle read-only transactions that are aborted

The commit for SERVER-38369 made commands that return raw shard responses return the first non-ignorable error as the top-level error, even if different non-ignorable errors occurred.
Branch: master
https://github.com/mongodb/mongo/commit/9a77424deeae44452042eed2c50747bd127b1b48

Comment by Githook User [ 07/May/19 ]

Author:

{'email': 'matthew.russotto@10gen.com', 'name': 'Matthew Russotto', 'username': 'mtrussotto'}

Message: SERVER-40996 abortTransaction in cleanup_txns.js does not handle different errors from different shards
Branch: master
https://github.com/mongodb/mongo/commit/ba844b4e81c3914b8a7017bd2a8c5ac4231c72ff

Comment by Githook User [ 07/May/19 ]

Author:

{'email': 'matthew.russotto@10gen.com', 'name': 'Matthew Russotto', 'username': 'mtrussotto'}

Message: SERVER-40996 abortTransaction in cleanup_txns.js does not handle LockTimeout
Branch: master
https://github.com/mongodb/mongo/commit/c1a481a79d5667b19053d0ad4ea177c8d56bd254

Comment by Matthew Russotto [ 03/May/19 ]

It appears we pass the set of error codes to be ignored into this function. This should be unnecessary since the set of codes should always be the same (though it's not now, that is likely an error).

Generated at Thu Feb 08 04:56:32 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.