Re: Maintaining cluster order on insert - Mailing list pgsql-patches

From Tom Lane
Subject Re: Maintaining cluster order on insert
Date
Msg-id 27526.1179500906@sss.pgh.pa.us
Whole thread Raw
In response to Re: Maintaining cluster order on insert  (Heikki Linnakangas <heikki@enterprisedb.com>)
Responses Re: Maintaining cluster order on insert
List pgsql-patches
Heikki Linnakangas <heikki@enterprisedb.com> writes:
> The beef of the patch is two new optional indexam API functions:
> amprepareinsert and amfinishinsert. amprepareinsert is called before
> inserting the heap tuple. It descends the tree and finds and pins the
> right leaf page to insert to, and returns a suggestion on where the heap
> tuple should be inserted. amfinishinsert is called after inserting the
> heap tuple to actually insert the index tuple. Documentation for these
> functions need to be added indexam.sgml, I noticed that that's not done yet.

What happens when there's more than one index?

Is there a risk of deadlock during concurrent insertions (from different
processes trying to lock the same buffers in different orders)?

            regards, tom lane

pgsql-patches by date:

Previous
From: Tom Lane
Date:
Subject: Re: CREATE TABLE LIKE INCLUDING INDEXES support
Next
From: Heikki Linnakangas
Date:
Subject: Re: Maintaining cluster order on insert