[SERVER-38182] run_check_repl_dbhash_background aborts all transactions after an error even if they've already successfully committed Created: 16/Nov/18  Updated: 29/Oct/23  Resolved: 27/Dec/18

Status: Closed
Project: Core Server
Component/s: Testing Infrastructure
Affects Version/s: None
Fix Version/s: 4.0.6, 4.1.7

Type: Bug Priority: Major - P3
Reporter: Samyukta Lanka Assignee: Max Hirschhorn
Resolution: Fixed Votes: 0
Labels: tig-dataconsistency
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
Duplicate
is duplicated by SERVER-38853 run_check_repl_dbhash_background.js s... Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Backport Requested:
v4.0
Sprint: STM 2018-12-31, STM 2019-01-14
Participants:
Linked BF Score: 0
Story Points: 2

 Description   

The dbHash command is run inside of a transaction in run_check_repl_dbhash_background.js on each node in the test's replica set. When committing the transactions, we will iterate over each session (one per node) and call commitTransaction. If any of these calls throws an error, we catch the error and iterate over each session to try to abort each transaction. But if any transaction was already successfully committed, trying to abort it errors with:

Error: Cannot call abortTransaction after calling commitTransaction. :

We should only try to abort transactions that are still active.



 Comments   
Comment by Githook User [ 27/Dec/18 ]

Author:

{'username': 'visemet', 'email': 'max.hirschhorn@mongodb.com', 'name': 'Max Hirschhorn'}

Message: SERVER-38182 Avoid calling abortTransaction() after txn committed.

(cherry picked from commit 7b72db38ae0121b3df3ac2f5bcbe6ea446ead3cb)
Branch: v4.0
https://github.com/mongodb/mongo/commit/38c0f8331a2d3fc35d6a2e3bd46fbc93f28309fb

Comment by Githook User [ 27/Dec/18 ]

Author:

{'username': 'visemet', 'email': 'max.hirschhorn@mongodb.com', 'name': 'Max Hirschhorn'}

Message: SERVER-38182 Avoid calling abortTransaction() after txn committed.
Branch: master
https://github.com/mongodb/mongo/commit/7b72db38ae0121b3df3ac2f5bcbe6ea446ead3cb

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