3. Implement an extra indexAM API call that allows indexAM to decide
when/if index is valid during recovery. This would also cover the second
concern neatly in a single API call.

wait until after deadline to implement (2) or (3), in case somebody
fixes this up in the next few weeks.


IMHO, Without locking of pages in recovery mode Btree and GIN are not usable while incomplete split exists - there is a nonconnected branch in tree.

GiST has similar issue - incomplete insert. One insertion in leaf page can produce updating of keys up to the root. During that split pages may occurs. So, it's needed to add to gistxlog.c tracking of pages split to get exact knowledge about moments of unusability of index.

One more thing about GiST - when database is switched from recovery mode to the normal mode then it's needed to complete insertion in GiST and, possibly, vacuum index. Dig around GistBulkDeleteResult->needFullVacuum and gistContinueInsert()

--
Teodor Sigaev                                   E-mail: [EMAIL PROTECTED]
                                                   WWW: http://www.sigaev.ru/

--
Sent via pgsql-hackers mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to