Tom Lane wrote:
> Alvaro Herrera <alvherre@commandprompt.com> writes:
> > The part about actually advancing relfrozenxid is still not done though ...
>
> Right. Are you intending to make that happen?
See attached patch. I'm intending to apply this sometime tomorrow.
Note that affecting CLUSTER changes code used by the ALTER TABLE
rewriting stuff as well; so with this patch, the latter also advances
relfrozenxid. I could have chosen to keep it as it was, but instead I
chose RecentXmin as the new freeze point. This is correct, because when
the table is rewritten, all the tuples are marked the rewriting
transaction's Xid, so for all purposes it behaves like a new table.
Curiously enough, TOAST tables are handled as fallout of other code, so
we don't need to do anything additional for this to work.
--
Alvaro Herrera http://www.CommandPrompt.com/
PostgreSQL Replication, Consulting, Custom Development, 24x7 support