Re: Re: COPY FREEZE and setting PD_ALL_VISIBLE/visibility map bits

David Steele <david@pgmasters.net>

From: David Steele <david@pgmasters.net>
To: Pavan Deolasee <pavan.deolasee@gmail.com>
Cc: Masahiko Sawada <sawada.mshk@gmail.com>, pgsql-hackers <pgsql-hackers@postgresql.org>, Jeff Janes <jeff.janes@gmail.com>, Simon Riggs <simon@2ndquadrant.com>
Date: 2019-03-20T10:30:53Z
Lists: pgsql-hackers
Hi Pavan,

On 3/14/19 2:20 PM, Masahiko Sawada wrote:
> On Thu, Mar 14, 2019 at 5:17 PM Pavan Deolasee <pavan.deolasee@gmail.com> wrote:
>>
>> Ok. I will run some tests. But please note that this patch is a bug fix to address the performance issue that is caused by having to rewrite the entire table when all-visible bit is set on the page during first vacuum. So while we may do some more work during COPY FREEZE, we're saving a lot of page writes during next vacuum. Also, since the scan that we are doing in this patch is done on a page that should be in the buffer cache, we will pay a bit in terms of CPU cost, but not anything in terms of IO cost.
> 
> Agreed. I had been misunderstanding this patch. The page scan during
> COPY FREEZE is necessary and it's very cheaper than doing in the first
> vacuum.

I have removed Ibrar as a reviewer since there has been no review from 
them in three weeks, and too encourage others to have a look.

Regards,
-- 
-David
david@pgmasters.net


Commits

  1. Fix COPY FREEZE with CLOBBER_CACHE_ALWAYS

  2. Set PD_ALL_VISIBLE and visibility map bits in COPY FREEZE

  3. docs: client certificates are always sent to the server

  4. Mark commit and abort WAL records with XLR_SPECIAL_REL_UPDATE.

  5. docs: land height is "elevation", not "altitude"

  6. Improve the internal implementation of ereport().