Re: optimizing vacuum truncation scans - Mailing list pgsql-hackers

From Jim Nasby
Subject Re: optimizing vacuum truncation scans
Date
Msg-id 55B6B195.9090601@BlueTreble.com
Whole thread Raw
In response to Re: optimizing vacuum truncation scans  (Robert Haas <robertmhaas@gmail.com>)
List pgsql-hackers
On 7/27/15 10:39 AM, Robert Haas wrote:
> But that's not enough: we also need to know that any tuple that
> survived the prune operation (that is, it wasn't redirected or marked
> unused) has a new-enough xmin, which isn't tracked anywhere.

Wouldn't that be old-enough xmin?

heap_prune_chain() is already calling HeapTupleSatisfiesVacuum, so it 
should be able to figure out if the page is all visible without a lot of 
extra work, and pass that info back to heap_page_prune (which would then 
pass it down to _execute()).

Definitely not a one-liner though.
-- 
Jim Nasby, Data Architect, Blue Treble Consulting, Austin TX
Data in Trouble? Get it in Treble! http://BlueTreble.com



pgsql-hackers by date:

Previous
From: Joel Jacobson
Date:
Subject: Re: Autonomous Transaction is back
Next
From: Josh Berkus
Date:
Subject: Re: Autonomous Transaction is back