[SERVER-64413] Make SessionCatalogMigrationSource ignore internal transactions for non-retryable writes and uncommitted internal transactions for retryable writes Created: 10/Mar/22  Updated: 29/Oct/23  Resolved: 16/Mar/22

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 5.3.0-rc4

Type: Task Priority: Major - P3
Reporter: Cheahuychou Mao Assignee: Cheahuychou Mao
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
is depended on by SERVER-63494 Transfer history for retryable transa... Closed
Backwards Compatibility: Fully Compatible
Sprint: Sharding NYC 2022-03-21
Participants:

 Description   

The SessionCatalogMigrationSource currently returns a dead-end sentinel noop oplog entry for every transaction involving the collection being migrated. For an internal transaction for non-retryable writes, this oplog entry is expected to cause the migration to hit this invariant inside checkStatementExecuted since retryable writes are not allowed inside an internal session for non-retryable writes. This issue will be handled in SERVER-64331. For now, the SessionCatalogMigrationSource should ignore internal transactions for non-retryable writes, just like what ReshardingOplogSessionApplication does in SERVER-63441.

Similarly, the SessionCatalogMigrationSource should also ignore internal transactions for retryable writes that are aborted or still in progress/prepare at the start of cloning since there is no write history to transfer (at this point). If any of the transactions commits during the migration, it will be handled through the transfer mod session migration queue (in SERVER-63494). 



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

Author:

{'name': 'Cheahuychou Mao', 'email': 'mao.cheahuychou@gmail.com', 'username': 'cheahuychou'}

Message: SERVER-64413 Make SessionCatalogMigrationSource ignore internal transactions for non-retryable writes and uncommitted internal transactions for retryable writes
Branch: master
https://github.com/mongodb/mongo/commit/f801cb26949e709161b9673eb5fa9e39d641b17d

Generated at Thu Feb 08 06:00:16 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.