[SERVER-35809] Never implicitly abort prepared transactions Created: 26/Jun/18  Updated: 29/Oct/23  Resolved: 10/Aug/18

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

Type: Task Priority: Major - P3
Reporter: Gregory McKeon (Inactive) Assignee: Siyuan Zhou
Resolution: Fixed Votes: 0
Labels: prepare_errors
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Problem/Incident
Related
Backwards Compatibility: Fully Compatible
Sprint: Repl 2018-07-30, Repl 2018-08-13
Participants:
Linked BF Score: 59

 Description   
  • Includes changes to
    • the Session reaper
    • the killSessions command
    • the transaction timeout
    • implicit abort on commitTransaciton errors
    • implicit abort on beginning a new transaction
    • chunk migration changes
  • Does not include stepdown or shutdown


 Comments   
Comment by Githook User [ 10/Aug/18 ]

Author:

{'name': 'Siyuan Zhou', 'email': 'siyuan.zhou@mongodb.com', 'username': 'visualzhou'}

Message: SERVER-35809 Never implicitly abort prepared transactions
Branch: master
https://github.com/mongodb/mongo/commit/3927b187d07cd5e9c9ebba26ecf9500b261f57fc

Comment by Githook User [ 30/Jul/18 ]

Author:

{'username': 'visualzhou', 'name': 'Siyuan Zhou', 'email': 'siyuan.zhou@mongodb.com'}

Message: SERVER-35809 Refactor transaction abort.
Branch: master
https://github.com/mongodb/mongo/commit/6a8543890960053d1d59c62a43a8804a23fe8f06

Comment by Githook User [ 30/Jul/18 ]

Author:

{'username': 'visualzhou', 'name': 'Siyuan Zhou', 'email': 'siyuan.zhou@mongodb.com'}

Message: SERVER-35809 Change transaction state enum class to enum.
Branch: master
https://github.com/mongodb/mongo/commit/0dc542ad4b37f5bbffd1422374e30984b98e2de3

Comment by Githook User [ 23/Jul/18 ]

Author:

{'username': 'visualzhou', 'name': 'Siyuan Zhou', 'email': 'siyuan.zhou@mongodb.com'}

Message: SERVER-35809 Remove unnecessary usage of the Client lock in session.cpp
Branch: master
https://github.com/mongodb/mongo/commit/92147dc38d0fe8f22b3a9fc31ed989e5ba703e3f

Comment by Judah Schvimer [ 03/Jul/18 ]

As part of this ticket, please remove this unnecessary usage of the Client lock and clarify the locking rules for the Client lock. Per schwerin, the Client lock is needed for changes that are legal to observe from off-thread. Per tess.avitabile, we lock the Client when changing the Locker on the OperationContext, since it's accessed from serverStatus/currentOp. We do not need to lock the client to change the RecoveryUnit on the OperationContext.

Comment by Judah Schvimer [ 02/Jul/18 ]

As part of this work, we should revisit this code and see if we can merge it in with existing code paths: https://github.com/mongodb/mongo/blob/08c906d4691f977c0a007780d9adc5128764eb35/src/mongo/db/session.cpp#L1028-L1052

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