On Sun, 2008-11-09 at 20:18 -0500, Tom Lane wrote: > Simon Riggs <[EMAIL PROTECTED]> writes: > > Will think some more and report back. > > If you want to do some more development, here's the portion of the > patch as yet unapplied --- will save you extracting it for yourself.
Thanks. More thought tells me that we should have a LockRelationForCatalogUpdate() that uses nearly the same design pattern as LockRelationForExtension(). There is no lockmode since we always take the lock in exclusive mode. Callers would grab the catalog update lock, re-read catalog, assemble the new tuple, make in-place update and release lock. Lock is non-transactional and exists only to serialise catalog updates from concurrent DDL operations. We then have the rule that all callers of heap_inplace_update() must already hold the catalog update lock. You like? -- Simon Riggs www.2ndQuadrant.com PostgreSQL Training, Services and Support -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers