summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEtienne Petrel <etienne.petrel@mongodb.com>2022-01-04 06:11:23 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2022-01-04 06:38:34 +0000
commit7d70b156eb30a857b372f671dc078173f66810b5 (patch)
treee6e32ac627ec35eca2d3166af07fa8affa3ac3c9
parent5d764dbb24dea2f88a464ad522925030e957b5ae (diff)
downloadmongo-7d70b156eb30a857b372f671dc078173f66810b5.tar.gz
Import wiredtiger: 4e5a6281aeca1bcc78639fb8ff7f05f2c54fde41 from branch mongodb-master
ref: d1e3d80d51..4e5a6281ae for: 5.3.0 WT-8617 Temporary fix for transaction snapshot assert.
-rw-r--r--src/third_party/wiredtiger/import.data2
-rw-r--r--src/third_party/wiredtiger/src/include/txn_inline.h5
2 files changed, 4 insertions, 3 deletions
diff --git a/src/third_party/wiredtiger/import.data b/src/third_party/wiredtiger/import.data
index 23b710ea98c..c6adc41230d 100644
--- a/src/third_party/wiredtiger/import.data
+++ b/src/third_party/wiredtiger/import.data
@@ -2,5 +2,5 @@
"vendor": "wiredtiger",
"github": "wiredtiger/wiredtiger.git",
"branch": "mongodb-master",
- "commit": "d1e3d80d51130e3ff7003a88dc1e388090761f63"
+ "commit": "4e5a6281aeca1bcc78639fb8ff7f05f2c54fde41"
}
diff --git a/src/third_party/wiredtiger/src/include/txn_inline.h b/src/third_party/wiredtiger/src/include/txn_inline.h
index 96717ab4f92..ccfae2af21d 100644
--- a/src/third_party/wiredtiger/src/include/txn_inline.h
+++ b/src/third_party/wiredtiger/src/include/txn_inline.h
@@ -716,8 +716,9 @@ __txn_visible_id(WT_SESSION_IMPL *session, uint64_t id)
if (txn->isolation == WT_ISO_READ_UNCOMMITTED)
return (true);
- /* Otherwise, we should be called with a snapshot. */
- WT_ASSERT(session, F_ISSET(txn, WT_TXN_HAS_SNAPSHOT) || session->dhandle->checkpoint != NULL);
+ /* Otherwise, we need a snapshot; if we don't have one, assume a test for global visibility. */
+ if (!F_ISSET(txn, WT_TXN_HAS_SNAPSHOT))
+ return (__txn_visible_all_id(session, id));
return (__wt_txn_visible_id_snapshot(
id, txn->snap_min, txn->snap_max, txn->snapshot, txn->snapshot_count));