[SERVER-39942] Extract transaction library from catalog_raii library Created: 04/Mar/19  Updated: 29/Oct/23  Resolved: 22/Mar/19

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

Type: Improvement Priority: Major - P3
Reporter: Jason Chan Assignee: Siyuan Zhou
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
related to SERVER-39441 Write the new prepare command on primary Closed
Backwards Compatibility: Fully Compatible
Sprint: Repl 2019-03-25
Participants:

 Description   

Currently, the transaction code is part of theĀ catalog_raii target in src/mongo/db/SConscript. We should evaluate whether it makes sense to keep the transaction code in catalog_raii in order to reduce the possibility of encountering circular dependencies in the future.

Initially, the transaction code used to live inside session.cpp but was refactored out into transaction_participant.cpp. There exists a dependency between TransactionParticipant and LockManager where we need to be able to know whether a read command is inside a transaction in order to decide whether to acquire a mode IS or mode IX lock. It would be helpful to investigate these dependencies in greater detail in order to prevent more tech debt.



 Comments   
Comment by Githook User [ 22/Mar/19 ]

Author:

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

Message: SERVER-39942 Make dependencies on transaction library private.
Branch: master
https://github.com/mongodb/mongo/commit/b5f3dc8f510bf9ba5e3ea5e5c0e6e2adcff66174

Comment by Githook User [ 15/Mar/19 ]

Author:

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

Message: SERVER-39942 Extract transaction library from catalog_raii library.
Branch: master
https://github.com/mongodb/mongo/commit/c346f2db39f1ddae16ecf8643041e19a31a83d84

Comment by Siyuan Zhou [ 14/Mar/19 ]

This is blocking the change stream work in SERVER-39675, so I'm prioritizing it. CC tess.avitabile.

Comment by Jason Chan [ 05/Mar/19 ]

william.schultz mentioned that we have a tool called Dagger that is able to track the build dependency data for the mongoDB project and output the graph into a json file. It may be worth it to investigate incorporating some visualization tools to output the graph into something more readable.

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