1
0
mirror of https://github.com/postgres/postgres.git synced 2025-10-25 13:17:41 +03:00

Make btree index structure adjustments and WAL logging changes needed to

support btree compaction, as per proposal of a few days ago.  btree index
pages no longer store parent links, instead they have a level indicator
(counting up from zero for leaf pages).  The FixBTree recovery logic is
removed, and replaced by code that detects missing parent-level insertions
during WAL replay.  Also, generate appropriate WAL entries when updating
btree metapage and when building a btree index from scratch.  I believe
btree indexes are now completely WAL-legal for the first time.
initdb forced due to index and WAL changes.
This commit is contained in:
Tom Lane
2003-02-21 00:06:22 +00:00
parent 4df0f1d26f
commit 70508ba7ae
13 changed files with 2179 additions and 1875 deletions

View File

@@ -6,7 +6,7 @@
* Portions Copyright (c) 1996-2002, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
* $Id: xlog.h,v 1.40 2002/11/15 02:44:57 momjian Exp $
* $Id: xlog.h,v 1.41 2003/02/21 00:06:22 tgl Exp $
*/
#ifndef XLOG_H
#define XLOG_H
@@ -145,10 +145,12 @@ typedef XLogPageHeaderData *XLogPageHeader;
*/
typedef struct RmgrData
{
char *rm_name;
const char *rm_name;
void (*rm_redo) (XLogRecPtr lsn, XLogRecord *rptr);
void (*rm_undo) (XLogRecPtr lsn, XLogRecord *rptr);
void (*rm_desc) (char *buf, uint8 xl_info, char *rec);
void (*rm_startup) (void);
void (*rm_cleanup) (void);
} RmgrData;
extern RmgrData RmgrTable[];