Skip site navigation (1) Skip section navigation (2)

pgsql: Derive latestRemovedXid for btree deletes by reading heap pages.

From: sriggs(at)postgresql(dot)org (Simon Riggs)
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Derive latestRemovedXid for btree deletes by reading heap pages.
Date: 2010-03-28 09:27:02
Message-ID: 20100328092702.3082F7541D0@cvs.postgresql.org (view raw or flat)
Thread:
Lists: pgsql-committers
Log Message:
-----------
Derive latestRemovedXid for btree deletes by reading heap pages. The
WAL record for btree delete contains a list of tids, even when backup
blocks are present. We follow the tids to their heap tuples, taking
care to follow LP_REDIRECT tuples. We ignore LP_DEAD tuples on the
understanding that they will always have xmin/xmax earlier than any
LP_NORMAL tuples referred to by killed index tuples. Iff all tuples
are LP_DEAD we return InvalidTransactionId. The heap relfilenode is
added to the WAL record, requiring API changes to pass down the heap
Relation. XLOG_PAGE_MAGIC updated.

Modified Files:
--------------
    pgsql/src/backend/access/nbtree:
        nbtinsert.c (r1.177 -> r1.178)
        (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/access/nbtree/nbtinsert.c?r1=1.177&r2=1.178)
        nbtpage.c (r1.121 -> r1.122)
        (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/access/nbtree/nbtpage.c?r1=1.121&r2=1.122)
        nbtree.c (r1.176 -> r1.177)
        (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/access/nbtree/nbtree.c?r1=1.176&r2=1.177)
        nbtxlog.c (r1.63 -> r1.64)
        (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/access/nbtree/nbtxlog.c?r1=1.63&r2=1.64)
    pgsql/src/include/access:
        nbtree.h (r1.133 -> r1.134)
        (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/include/access/nbtree.h?r1=1.133&r2=1.134)
        xlog_internal.h (r1.30 -> r1.31)
        (http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/include/access/xlog_internal.h?r1=1.30&r2=1.31)

pgsql-committers by date

Next:From: Tom LaneDate: 2010-03-28 22:59:34
Subject: pgsql: Rework join-removal logic as per recent discussion.
Previous:From: Simon RiggsDate: 2010-03-28 08:52:44
Subject: Re: [COMMITTERS] pgsql: Augment WAL records for btree delete with GetOldestXmin() to

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group