From: Alexander Korotkov <akorotkov@postgresql.org>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Remove btree page items after page unlink
Date: Tue, 04 Aug 2020 23:16:24 +0000
Message-ID: <E1k36AS-0003x1-Ov@gemulon.postgresql.org> (raw)
Remove btree page items after page unlink
Currently, page unlink leaves remaining items "as is", but replay of
corresponding WAL-record re-initializes page leaving it with no items.
For the sake of consistency, this commit makes primary delete all the items
during page unlink as well.
Thanks to this change, we now don't mask contents of deleted btree page for
WAL consistency checking.
Discussion: https://postgr.es/m/CAPpHfdt_OTyQpXaPJcWzV2N-LNeNJseNB-K_A66qG%3DL518VTFw%40mail.gmail.com
Author: Alexander Korotkov
Reviewed-by: Peter Geoghegan
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/f47b5e139579a77c1f7c63400f01ea39d515e8c8
Modified Files
--------------
contrib/amcheck/verify_nbtree.c | 7 ++-----
src/backend/access/nbtree/nbtpage.c | 9 +++++++++
src/backend/access/nbtree/nbtxlog.c | 10 +---------
3 files changed, 12 insertions(+), 14 deletions(-)
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-committers@postgresql.org
Cc: akorotkov@postgresql.org
Subject: Re: pgsql: Remove btree page items after page unlink
In-Reply-To: <E1k36AS-0003x1-Ov@gemulon.postgresql.org>
References: <E1k36AS-0003x1-Ov@gemulon.postgresql.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox