summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEtienne Petrel <etienne.petrel@mongodb.com>2022-03-14 04:17:28 +0000
committerEvergreen Agent <no-reply@evergreen.mongodb.com>2022-03-14 04:53:58 +0000
commit9ee8adbe9c617e4150d3691f3b0114340c0278b1 (patch)
tree8dcf451f6d00f03d66a8ece1efe00e76f38996d7
parentf5da0ae928daf0366aeba3391b2865147c83f4eb (diff)
downloadmongo-9ee8adbe9c617e4150d3691f3b0114340c0278b1.tar.gz
Import wiredtiger: 403df77b0a6452e1b3a21ce32eec5a21aefdbe08 from branch mongodb-master
ref: 23e5746ea9..403df77b0a for: 6.0.0 WT-8924 Don't check against on disk time window if there is an insert list when checking for conflicts in row-store
-rw-r--r--src/third_party/wiredtiger/import.data2
-rw-r--r--src/third_party/wiredtiger/src/include/txn_inline.h7
2 files changed, 7 insertions, 2 deletions
diff --git a/src/third_party/wiredtiger/import.data b/src/third_party/wiredtiger/import.data
index 86408a28926..a568a9d0fb1 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": "23e5746ea948e3b1ac903f2cce3ea209e19329a1"
+ "commit": "403df77b0a6452e1b3a21ce32eec5a21aefdbe08"
}
diff --git a/src/third_party/wiredtiger/src/include/txn_inline.h b/src/third_party/wiredtiger/src/include/txn_inline.h
index 7beeb00c44b..98a2a90d46f 100644
--- a/src/third_party/wiredtiger/src/include/txn_inline.h
+++ b/src/third_party/wiredtiger/src/include/txn_inline.h
@@ -1348,8 +1348,13 @@ __wt_txn_modify_check(
* Check conflict against any on-page value if there is no update on the update chain except
* aborted updates. Otherwise, we would have either already detected a conflict if we saw an
* uncommitted update or determined that it would be safe to write if we saw a committed update.
+ *
+ * In the case of row-store we also need to check that the insert list is empty as the existence
+ * of it implies there is no on disk value for the given key. However we can still get a
+ * time-window from an unrelated on-disk value if we are not careful as the slot can still be
+ * set on the cursor b-tree.
*/
- if (!rollback && upd == NULL) {
+ if (!rollback && upd == NULL && (CUR2BT(cbt)->type != BTREE_ROW || cbt->ins == NULL)) {
tw_found = __wt_read_cell_time_window(cbt, &tw);
if (tw_found) {
if (WT_TIME_WINDOW_HAS_STOP(&tw)) {