diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2001-07-15 22:48:19 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2001-07-15 22:48:19 +0000 |
commit | c8076f09d2eb82a28f27f97230be470fffe7a1e0 (patch) | |
tree | 1e357e7e28313386f9d2e789d3905b37ce2d58f6 /src/include/access/rtree.h | |
parent | 997439f59e1d487cb2bfa1384f6479fda0c4dd4c (diff) |
Restructure index AM interface for index building and index tuple deletion,
per previous discussion on pghackers. Most of the duplicate code in
different AMs' ambuild routines has been moved out to a common routine
in index.c; this means that all index types now do the right things about
inserting recently-dead tuples, etc. (I also removed support for EXTEND
INDEX in the ambuild routines, since that's about to go away anyway, and
it cluttered the code a lot.) The retail indextuple deletion routines have
been replaced by a "bulk delete" routine in which the indexscan is inside
the access method. I haven't pushed this change as far as it should go yet,
but it should allow considerable simplification of the internal bookkeeping
for deletions. Also, add flag columns to pg_am to eliminate various
hardcoded tests on AM OIDs, and remove unused pg_am columns.
Fix rtree and gist index types to not attempt to store NULLs; before this,
gist usually crashed, while rtree managed not to crash but computed wacko
bounding boxes for NULL entries (which might have had something to do with
the performance problems we've heard about occasionally).
Add AtEOXact routines to hash, rtree, and gist, all of which have static
state that needs to be reset after an error. We discovered this need long
ago for btree, but missed the other guys.
Oh, one more thing: concurrent VACUUM is now the default.
Diffstat (limited to 'src/include/access/rtree.h')
-rw-r--r-- | src/include/access/rtree.h | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/include/access/rtree.h b/src/include/access/rtree.h index 210e8739814..237937fe46a 100644 --- a/src/include/access/rtree.h +++ b/src/include/access/rtree.h @@ -7,7 +7,7 @@ * Portions Copyright (c) 1996-2001, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $Id: rtree.h,v 1.23 2001/05/30 19:53:39 tgl Exp $ + * $Id: rtree.h,v 1.24 2001/07/15 22:48:18 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -110,7 +110,7 @@ extern void freestack(RTSTACK *s); * Defined in access/rtree/ */ extern Datum rtinsert(PG_FUNCTION_ARGS); -extern Datum rtdelete(PG_FUNCTION_ARGS); +extern Datum rtbulkdelete(PG_FUNCTION_ARGS); extern Datum rtgettuple(PG_FUNCTION_ARGS); extern Datum rtbeginscan(PG_FUNCTION_ARGS); @@ -129,6 +129,7 @@ extern void rtree_desc(char *buf, uint8 xl_info, char *rec); /* rtscan.c */ extern void rtadjscans(Relation r, int op, BlockNumber blkno, OffsetNumber offnum); +extern void AtEOXact_rtree(void); /* rtstrat.c */ extern RegProcedure RTMapOperator(Relation r, AttrNumber attnum, |