On Thursday, December 20, 2012 6:14 AM Robert Haas wrote: > On Wed, Dec 19, 2012 at 12:39 PM, Simon Riggs <si...@2ndquadrant.com> > wrote: > > The benefit of saying that only UPDATEs clean the block is that this > > penalises only the workload making the mess, rather than everybody > > cleaning up repeatedly over one messy guy. > > Right, but there are plenty of situations where having everybody clean > up after the messy guy is better than waiting around and hoping that > Mom (aka vacuum) will do it.
If we see for similar situation in index, during index scan, it just marks the tuple as DEAD without taking X lock and then during split (when it already has X lock) it free's the actual space. So not sure if it's good idea to take X lock for cleanup during heap scan, where write operation's happens more frequently and have better chance of cleanup. With Regards, Amit Kapila. -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers