diff options
author | Luke Chen <luke.chen@mongodb.com> | 2023-01-05 12:53:45 +1100 |
---|---|---|
committer | Evergreen Agent <no-reply@evergreen.mongodb.com> | 2023-01-05 02:35:30 +0000 |
commit | 9cb12492d5a3b38a774d9075feb383adf3e1e087 (patch) | |
tree | ddf6257a4b6fc95f21e41555471d075c543a8459 | |
parent | 4e43d253cc701d4a019143ca0424222df1248cb6 (diff) | |
download | mongo-9cb12492d5a3b38a774d9075feb383adf3e1e087.tar.gz |
Import wiredtiger: d31db8f8be34e8ec6b584a1602eee7710243d085 from branch mongodb-6.0
ref: 265f4fe439..d31db8f8be
for: 6.0.4
WT-10062 Fix checkpoint cleanup not to skip internal pages
-rw-r--r-- | src/third_party/wiredtiger/import.data | 2 | ||||
-rw-r--r-- | src/third_party/wiredtiger/src/btree/bt_sync.c | 18 |
2 files changed, 16 insertions, 4 deletions
diff --git a/src/third_party/wiredtiger/import.data b/src/third_party/wiredtiger/import.data index 11ffeb6b841..099e6426b82 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-6.0", - "commit": "265f4fe4398dc13f8a13ad285a66c92d2e11cb98" + "commit": "d31db8f8be34e8ec6b584a1602eee7710243d085" } diff --git a/src/third_party/wiredtiger/src/btree/bt_sync.c b/src/third_party/wiredtiger/src/btree/bt_sync.c index 63a2a5622b7..6c25122f28b 100644 --- a/src/third_party/wiredtiger/src/btree/bt_sync.c +++ b/src/third_party/wiredtiger/src/btree/bt_sync.c @@ -380,10 +380,22 @@ __sync_page_skip( return (0); /* - * Skip reading the pages that are normal leaf pages or don't have an aggregated durable stop - * timestamp. + * The checkpoint cleanup fast deletes the obsolete leaf page by marking it as deleted + * in the internal page. To achieve this, + * + * 1. Checkpoint has to read all the internal pages that have obsolete leaf pages. + * To limit the reading of number of internal pages, the aggregated stop durable timestamp + * is checked except when the table is logged. Logged tables do not use timestamps. + * + * 2. Obsolete leaf pages with overflow keys/values cannot be fast deleted to free + * the overflow blocks. Read the page into cache and mark it dirty to remove the + * overflow blocks during reconciliation. + * + * FIXME: Read internal pages from non-logged tables when the remove/truncate + * operation is performed using no timestamp. */ - if (addr.type == WT_ADDR_LEAF_NO || addr.ta.newest_stop_durable_ts == WT_TS_NONE) { + if (addr.type == WT_ADDR_LEAF_NO || + (!F_ISSET(S2BT(session), WT_BTREE_LOGGED) && addr.ta.newest_stop_durable_ts == WT_TS_NONE)) { __wt_verbose(session, WT_VERB_CHECKPOINT_CLEANUP, "%p: page walk skipped", (void *)ref); WT_STAT_CONN_DATA_INCR(session, cc_pages_walk_skipped); *skipp = true; |